Skip to content

Commit d189f3b

Browse files
committed
notebook update
1 parent d1be43e commit d189f3b

File tree

1 file changed

+241
-6
lines changed

1 file changed

+241
-6
lines changed

example_local_infresnel.ipynb

Lines changed: 241 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,20 @@
5959
"execution_count": 2,
6060
"id": "9cf71665",
6161
"metadata": {},
62-
"outputs": [],
62+
"outputs": [
63+
{
64+
"name": "stdout",
65+
"output_type": "stream",
66+
"text": [
67+
"Downloading and resampling DEM...\n",
68+
"Creating output file that is 253P x 260L.\n",
69+
"Using internal nodata values (e.g. 0) for image /var/folders/kt/r_9qxn7d6wgc0lwylt3t3qx8bb196z/T/tmpt5e3xzg3.\n",
70+
"Copying nodata values from source /var/folders/kt/r_9qxn7d6wgc0lwylt3t3qx8bb196z/T/tmpt5e3xzg3 to destination DEM_WGS84_resampled.tif.\n",
71+
"Processing /var/folders/kt/r_9qxn7d6wgc0lwylt3t3qx8bb196z/T/tmpt5e3xzg3 [1/1] : 0...10...20...30...40...50...60...70...80...90...100 - done.\n",
72+
"Done\n"
73+
]
74+
}
75+
],
6376
"source": [
6477
"DEM_URL = 'https://opentopography.s3.sdsc.edu/dataspace/OTDS.072019.4326.1/raster/DEM_WGS84.tif'\n",
6578
"dem_file = 'DEM_WGS84_resampled.tif'\n",
@@ -240,17 +253,239 @@
240253
"name": "stderr",
241254
"output_type": "stream",
242255
"text": [
243-
"/Users/ltoney/repos/rtm/rtm/grid.py:480: RuntimeWarning: invalid value encountered in cast\n",
244-
" st[0].stats.sampling_rate).astype(int)\n"
256+
"/Users/ltoney/repos/rtm/rtm/travel_time.py:409: UserWarning: 52.3% of DEM is NaN!\n",
257+
" _diff_path_lens = calculate_paths(\n"
245258
]
246259
},
247260
{
248261
"name": "stdout",
249262
"output_type": "stream",
250263
"text": [
251264
"----------------------------------------------------------------\n",
252-
"LOADING TRAVEL TIMES FROM diff_path_lens.nc WITH CELERITY = 343 M/S\n",
265+
"CALCULATING TRAVEL TIMES USING INFRESNEL WITH CELERITY = 343 M/S\n",
253266
"----------------------------------------------------------------\n",
267+
"\n",
268+
"(1/5) Station 3E.YIF1.01.CDF\n",
269+
"\n",
270+
"Loading and projecting DEM...\n",
271+
"Done\n",
272+
"\n",
273+
"DEM spacing = 5.40 m -> profile spacing = 2.70 m\n",
274+
"\n",
275+
"Checking that DEM contains source and receivers...\n",
276+
"Done — 6934 invalid paths will be set to NaN\n",
277+
"\n",
278+
"Fitting spline to DEM...\n",
279+
"Done\n",
280+
"\n",
281+
"Computing 15851 paths...\n"
282+
]
283+
},
284+
{
285+
"data": {
286+
"application/vnd.jupyter.widget-view+json": {
287+
"model_id": "dcae3740fb014c62b4d5b5dfbf2bacc7",
288+
"version_major": 2,
289+
"version_minor": 0
290+
},
291+
"text/plain": [
292+
" 0% | | 0/15851 paths "
293+
]
294+
},
295+
"metadata": {},
296+
"output_type": "display_data"
297+
},
298+
{
299+
"name": "stderr",
300+
"output_type": "stream",
301+
"text": [
302+
"/Users/ltoney/repos/rtm/rtm/travel_time.py:409: UserWarning: 52.3% of DEM is NaN!\n",
303+
" _diff_path_lens = calculate_paths(\n"
304+
]
305+
},
306+
{
307+
"name": "stdout",
308+
"output_type": "stream",
309+
"text": [
310+
"Done\n",
311+
"\n",
312+
"(2/5) Station 3E.YIF2.01.CDF\n",
313+
"\n",
314+
"Loading and projecting DEM...\n",
315+
"Done\n",
316+
"\n",
317+
"DEM spacing = 5.40 m -> profile spacing = 2.70 m\n",
318+
"\n",
319+
"Checking that DEM contains source and receivers...\n",
320+
"Done — 6934 invalid paths will be set to NaN\n",
321+
"\n",
322+
"Fitting spline to DEM...\n",
323+
"Done\n",
324+
"\n",
325+
"Computing 15851 paths...\n"
326+
]
327+
},
328+
{
329+
"data": {
330+
"application/vnd.jupyter.widget-view+json": {
331+
"model_id": "51208a0bb7f74ece97505ee57203766a",
332+
"version_major": 2,
333+
"version_minor": 0
334+
},
335+
"text/plain": [
336+
" 0% | | 0/15851 paths "
337+
]
338+
},
339+
"metadata": {},
340+
"output_type": "display_data"
341+
},
342+
{
343+
"name": "stderr",
344+
"output_type": "stream",
345+
"text": [
346+
"/Users/ltoney/repos/rtm/rtm/travel_time.py:409: UserWarning: 52.3% of DEM is NaN!\n",
347+
" _diff_path_lens = calculate_paths(\n"
348+
]
349+
},
350+
{
351+
"name": "stdout",
352+
"output_type": "stream",
353+
"text": [
354+
"Done\n",
355+
"\n",
356+
"(3/5) Station 3E.YIF3.01.CDF\n",
357+
"\n",
358+
"Loading and projecting DEM...\n",
359+
"Done\n",
360+
"\n",
361+
"DEM spacing = 5.40 m -> profile spacing = 2.70 m\n",
362+
"\n",
363+
"Checking that DEM contains source and receivers...\n",
364+
"Done — 6934 invalid paths will be set to NaN\n",
365+
"\n",
366+
"Fitting spline to DEM...\n",
367+
"Done\n",
368+
"\n",
369+
"Computing 15851 paths...\n"
370+
]
371+
},
372+
{
373+
"data": {
374+
"application/vnd.jupyter.widget-view+json": {
375+
"model_id": "4a342ff82fd64ef7bf2aba5c47cda8af",
376+
"version_major": 2,
377+
"version_minor": 0
378+
},
379+
"text/plain": [
380+
" 0% | | 0/15851 paths "
381+
]
382+
},
383+
"metadata": {},
384+
"output_type": "display_data"
385+
},
386+
{
387+
"name": "stderr",
388+
"output_type": "stream",
389+
"text": [
390+
"/Users/ltoney/repos/rtm/rtm/travel_time.py:409: UserWarning: 52.3% of DEM is NaN!\n",
391+
" _diff_path_lens = calculate_paths(\n"
392+
]
393+
},
394+
{
395+
"name": "stdout",
396+
"output_type": "stream",
397+
"text": [
398+
"Done\n",
399+
"\n",
400+
"(4/5) Station 3E.YIF4.01.CDF\n",
401+
"\n",
402+
"Loading and projecting DEM...\n",
403+
"Done\n",
404+
"\n",
405+
"DEM spacing = 5.40 m -> profile spacing = 2.70 m\n",
406+
"\n",
407+
"Checking that DEM contains source and receivers...\n",
408+
"Done — 6934 invalid paths will be set to NaN\n",
409+
"\n",
410+
"Fitting spline to DEM...\n",
411+
"Done\n",
412+
"\n",
413+
"Computing 15851 paths...\n"
414+
]
415+
},
416+
{
417+
"data": {
418+
"application/vnd.jupyter.widget-view+json": {
419+
"model_id": "43328ae8548f43f2be04fff65c1ac67b",
420+
"version_major": 2,
421+
"version_minor": 0
422+
},
423+
"text/plain": [
424+
" 0% | | 0/15851 paths "
425+
]
426+
},
427+
"metadata": {},
428+
"output_type": "display_data"
429+
},
430+
{
431+
"name": "stderr",
432+
"output_type": "stream",
433+
"text": [
434+
"/Users/ltoney/repos/rtm/rtm/travel_time.py:409: UserWarning: 52.3% of DEM is NaN!\n",
435+
" _diff_path_lens = calculate_paths(\n"
436+
]
437+
},
438+
{
439+
"name": "stdout",
440+
"output_type": "stream",
441+
"text": [
442+
"Done\n",
443+
"\n",
444+
"(5/5) Station 3E.YIF5.01.CDF\n",
445+
"\n",
446+
"Loading and projecting DEM...\n",
447+
"Done\n",
448+
"\n",
449+
"DEM spacing = 5.40 m -> profile spacing = 2.70 m\n",
450+
"\n",
451+
"Checking that DEM contains source and receivers...\n",
452+
"Done — 6934 invalid paths will be set to NaN\n",
453+
"\n",
454+
"Fitting spline to DEM...\n",
455+
"Done\n",
456+
"\n",
457+
"Computing 15851 paths...\n"
458+
]
459+
},
460+
{
461+
"data": {
462+
"application/vnd.jupyter.widget-view+json": {
463+
"model_id": "bf58c92e26d24a90ae3b166c230fcb40",
464+
"version_major": 2,
465+
"version_minor": 0
466+
},
467+
"text/plain": [
468+
" 0% | | 0/15851 paths "
469+
]
470+
},
471+
"metadata": {},
472+
"output_type": "display_data"
473+
},
474+
{
475+
"name": "stderr",
476+
"output_type": "stream",
477+
"text": [
478+
"/Users/ltoney/repos/rtm/rtm/grid.py:480: RuntimeWarning: invalid value encountered in cast\n",
479+
" st[0].stats.sampling_rate).astype(int)\n"
480+
]
481+
},
482+
{
483+
"name": "stdout",
484+
"output_type": "stream",
485+
"text": [
486+
"Done\n",
487+
"Done (elapsed time = 20 s)\n",
488+
"Diffracted path lengths saved to diff_path_lens.nc\n",
254489
"----------------------\n",
255490
"PERFORMING GRID SEARCH\n",
256491
"Method = 'sum'\n",
@@ -327,7 +562,8 @@
327562
"\t/Users/ltoney/repos/rtm/DEM_WGS84_resampled.tif\n",
328563
"Done\n",
329564
"Returning just global max!\n",
330-
"Unprojecting coordinates from UTM to (latitude, longitude).\n"
565+
"Unprojecting coordinates from UTM to (latitude, longitude).\n",
566+
"Converting to x/y grid, cropping 600 m from center\n"
331567
]
332568
},
333569
{
@@ -341,7 +577,6 @@
341577
"name": "stdout",
342578
"output_type": "stream",
343579
"text": [
344-
"Converting to x/y grid, cropping 600 m from center\n",
345580
"Found 1 peaks in stack for height > 3.0 and min_time > 2.0 s.\n",
346581
"Unprojecting coordinates from UTM to (latitude, longitude).\n"
347582
]

0 commit comments

Comments
 (0)