Initial work on bringing mag into simpeg framework