Skip to content

Commit cc21cf5

Browse files
authored
Merge pull request #97 from geoscixyz/gpr_add_notebooks
Gpr add notebooks
2 parents 241c49a + fdb27ca commit cc21cf5

File tree

5 files changed

+74
-37
lines changed

5 files changed

+74
-37
lines changed

Notebooks/GPR_Attenuation.ipynb

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -99,21 +99,21 @@
9999
"metadata": {
100100
"anaconda-cloud": {},
101101
"kernelspec": {
102-
"display_name": "Python [conda root]",
102+
"display_name": "Python 3",
103103
"language": "python",
104-
"name": "conda-root-py"
104+
"name": "python3"
105105
},
106106
"language_info": {
107107
"codemirror_mode": {
108108
"name": "ipython",
109-
"version": 2
109+
"version": 3
110110
},
111111
"file_extension": ".py",
112112
"mimetype": "text/x-python",
113113
"name": "python",
114114
"nbconvert_exporter": "python",
115-
"pygments_lexer": "ipython2",
116-
"version": "2.7.13"
115+
"pygments_lexer": "ipython3",
116+
"version": "3.6.6"
117117
},
118118
"widgets": {
119119
"state": {

Notebooks/GPR_Lab6_FitData.ipynb

Lines changed: 29 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,8 @@
2828
},
2929
{
3030
"cell_type": "code",
31-
"execution_count": 1,
32-
"metadata": {
33-
"collapsed": true
34-
},
31+
"execution_count": 7,
32+
"metadata": {},
3533
"outputs": [],
3634
"source": [
3735
"%matplotlib inline\n",
@@ -59,25 +57,30 @@
5957
},
6058
{
6159
"cell_type": "code",
62-
"execution_count": 2,
60+
"execution_count": 8,
6361
"metadata": {},
6462
"outputs": [
6563
{
6664
"data": {
6765
"application/vnd.jupyter.widget-view+json": {
68-
"model_id": "94b533cad0a54e598df4e27ade6ebe50"
69-
}
66+
"model_id": "0fa2798273f4471990b12b305ecbb46e",
67+
"version_major": 2,
68+
"version_minor": 0
69+
},
70+
"text/plain": [
71+
"interactive(children=(IntSlider(value=50, description='epsr'), FloatSlider(value=1.0, description='h', max=2.0…"
72+
]
7073
},
7174
"metadata": {},
7275
"output_type": "display_data"
7376
},
7477
{
7578
"data": {
7679
"text/plain": [
77-
"<function gpgLabs.GPR.GPRlab1.PipeWidgetFcn>"
80+
"<function gpgLabs.GPR.GPRlab1.PipeWidgetFcn(epsr, h, xc, r, imgcmp)>"
7881
]
7982
},
80-
"execution_count": 2,
83+
"execution_count": 8,
8184
"metadata": {},
8285
"output_type": "execute_result"
8386
}
@@ -108,27 +111,32 @@
108111
},
109112
{
110113
"cell_type": "code",
111-
"execution_count": 4,
114+
"execution_count": 9,
112115
"metadata": {
113-
"scrolled": true
116+
"scrolled": false
114117
},
115118
"outputs": [
116119
{
117120
"data": {
118121
"application/vnd.jupyter.widget-view+json": {
119-
"model_id": "9b6c195504c14ea38c09ac60dd1cc3c6"
120-
}
122+
"model_id": "ac5d5481f7994f93b54e634da9f0e920",
123+
"version_major": 2,
124+
"version_minor": 0
125+
},
126+
"text/plain": [
127+
"interactive(children=(IntSlider(value=50, description='epsr'), FloatSlider(value=1.0, description='h', max=2.0…"
128+
]
121129
},
122130
"metadata": {},
123131
"output_type": "display_data"
124132
},
125133
{
126134
"data": {
127135
"text/plain": [
128-
"<function gpgLabs.GPR.GPRlab1.WallWidgetFcn>"
136+
"<function gpgLabs.GPR.GPRlab1.WallWidgetFcn(epsr, h, x1, x2, imgcmp)>"
129137
]
130138
},
131-
"execution_count": 4,
139+
"execution_count": 9,
132140
"metadata": {},
133141
"output_type": "execute_result"
134142
}
@@ -142,31 +150,29 @@
142150
{
143151
"cell_type": "code",
144152
"execution_count": null,
145-
"metadata": {
146-
"collapsed": true
147-
},
153+
"metadata": {},
148154
"outputs": [],
149155
"source": []
150156
}
151157
],
152158
"metadata": {
153159
"anaconda-cloud": {},
154160
"kernelspec": {
155-
"display_name": "Python [conda root]",
161+
"display_name": "Python 3",
156162
"language": "python",
157-
"name": "conda-root-py"
163+
"name": "python3"
158164
},
159165
"language_info": {
160166
"codemirror_mode": {
161167
"name": "ipython",
162-
"version": 2
168+
"version": 3
163169
},
164170
"file_extension": ".py",
165171
"mimetype": "text/x-python",
166172
"name": "python",
167173
"nbconvert_exporter": "python",
168-
"pygments_lexer": "ipython2",
169-
"version": "2.7.13"
174+
"pygments_lexer": "ipython3",
175+
"version": "3.6.6"
170176
},
171177
"widgets": {
172178
"state": {

Notebooks/GPR_TBL4_DOI_Resolution.ipynb

Lines changed: 37 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
},
2323
{
2424
"cell_type": "code",
25-
"execution_count": 1,
25+
"execution_count": 4,
2626
"metadata": {},
2727
"outputs": [],
2828
"source": [
@@ -54,13 +54,36 @@
5454
},
5555
{
5656
"cell_type": "code",
57-
"execution_count": 2,
57+
"execution_count": 12,
58+
"metadata": {},
59+
"outputs": [
60+
{
61+
"data": {
62+
"text/plain": [
63+
"1.3416407864998738"
64+
]
65+
},
66+
"execution_count": 12,
67+
"metadata": {},
68+
"output_type": "execute_result"
69+
}
70+
],
71+
"source": [
72+
"fc = 250*1e6\n",
73+
"d = 6\n",
74+
"v = 3*1e8 / np.sqrt(4)\n",
75+
"np.sqrt(v*d / (2*fc))"
76+
]
77+
},
78+
{
79+
"cell_type": "code",
80+
"execution_count": 14,
5881
"metadata": {},
5982
"outputs": [
6083
{
6184
"data": {
6285
"application/vnd.jupyter.widget-view+json": {
63-
"model_id": "939fe164aae44aed869231a9df22d4e9",
86+
"model_id": "21d13f084aaa48768dba032d4db5f9fe",
6487
"version_major": 2,
6588
"version_minor": 0
6689
},
@@ -77,7 +100,7 @@
77100
"<function gpgLabs.GPR.GPR_zero_offset.GPRWidgetWaveRegime(sig, epsr, fc, x1, d1, R1, x2, d2, R2)>"
78101
]
79102
},
80-
"execution_count": 2,
103+
"execution_count": 14,
81104
"metadata": {},
82105
"output_type": "execute_result"
83106
}
@@ -107,13 +130,13 @@
107130
},
108131
{
109132
"cell_type": "code",
110-
"execution_count": 3,
133+
"execution_count": 15,
111134
"metadata": {},
112135
"outputs": [
113136
{
114137
"data": {
115138
"application/vnd.jupyter.widget-view+json": {
116-
"model_id": "89228aede5c54d3d8423e8244b46fa01",
139+
"model_id": "fbc99ffb253245358914d26a9d865717",
117140
"version_major": 2,
118141
"version_minor": 0
119142
},
@@ -130,14 +153,21 @@
130153
"<function gpgLabs.GPR.Attenuation.WaveVelandSkindWidgetTBL(epsr, sigma)>"
131154
]
132155
},
133-
"execution_count": 3,
156+
"execution_count": 15,
134157
"metadata": {},
135158
"output_type": "execute_result"
136159
}
137160
],
138161
"source": [
139162
"AttenuationWidgetTBL()"
140163
]
164+
},
165+
{
166+
"cell_type": "code",
167+
"execution_count": null,
168+
"metadata": {},
169+
"outputs": [],
170+
"source": []
141171
}
142172
],
143173
"metadata": {

Notebooks/index.ipynb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@
3838
"- <a href=\"Seis_VerticalResolution.ipynb\">Seis_VerticalResolution.ipynb</a> - Vertical resolution in reflection\n",
3939
"\n",
4040
"### Ground Penetrating Radar\n",
41-
"- <a href=\"GPR_Attenuation.ipynb\">GPR_Attenuation.ipynb</a> - EM attenuation in GPR\n",
42-
"- <a href=\"GPR_FitData.ipynb\">GPR_FitData.ipynb</a> - Fit field data\n",
41+
"- <a href=\"GPR_TBL4_DOI_Resolution.ipynb\">GPR_TBL4_DOI_Resolution.ipynb</a> - Horizontal resolution + Probing distance of GPR\n",
42+
"- <a href=\"GPR_Lab6_FitData.ipynb\">GPR_Lab6_FitData.ipynb</a> - Fit field GPR data\n",
4343
"\n",
4444
"### Electromagnetics\n",
4545
"- <a href=\"EM_ThreeLoopModel.ipynb\">EM_ThreeLoopModel.ipynb</a> - EM induction explained by a 3-loop circuit model\n",

gpgLabs/Mag/MagDipoleApp.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,7 @@ def plot_map(self):
345345
ax2.remove()
346346
else:
347347
ax1.plot(self.xy_profile[:, 0], self.xy_profile[:, 1], 'w')
348+
348349
def get_half_width(self, n_points=200):
349350
ind_max = np.argmax(abs(self.data_profile))
350351
A_half = self.data_profile[ind_max] / 2.

0 commit comments

Comments
 (0)