This is the Jupyter Notebook, an interactive coding and computation environment. For this lab, you do not have to write any code, you will only be running it.
To use the notebook:
This notebook uses code adapted from
SimPEG
import numpy as np
from geoscilabs.mag import Mag, Simulator
from discretize import TensorMesh
from SimPEG import utils
from SimPEG.potential_fields import magnetics as mag
from ipywidgets import widgets
import matplotlib
#Input parameters
fileName = 'http://github.com/geoscixyz/geosci-labs/raw/main/assets/mag/data/350mag2023.csv'
data = np.genfromtxt(fileName, skip_header=1, delimiter=',')
xyzd = np.c_[np.zeros(data.shape[0]), data[:,0], np.zeros(data.shape[0]), data[:,1]]
B = np.r_[60308, 83.8, 25.4]
survey, dobj = Mag.createMagSurvey(xyzd, B)
# View the data and chose a profile
# Define the parametric model interactively
model = Simulator.ViewPrism(survey)
model
interactive(children=(ToggleButton(value=False, description='Refresh'), FloatSlider(value=2.375, continuous_up…
Simulator.fitline(model,survey,dobj)
interactive(children=(FloatSlider(value=90.0, continuous_update=False, description='Binc', max=90.0, min=-90.0…