Skip to content

Commit 7412487

Browse files
committed
updated and added various notebooks
1 parent 45f2cc2 commit 7412487

File tree

7 files changed

+5214
-4085
lines changed

7 files changed

+5214
-4085
lines changed

notebooks/Amanda/apply_unet.ipynb

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -385,24 +385,24 @@
385385
},
386386
{
387387
"cell_type": "code",
388-
"execution_count": 44,
388+
"execution_count": 46,
389389
"id": "cd73f3e0",
390390
"metadata": {},
391391
"outputs": [
392392
{
393393
"name": "stdout",
394394
"output_type": "stream",
395395
"text": [
396-
"phase,time,index,confidence\n",
397-
"P,2022-12-20T00:01:40.038400Z,10003,0.327\n",
398-
"P,2022-12-20T00:01:41.648400Z,10164,0.789\n",
399-
"P,2022-12-20T00:01:45.568400Z,10556,0.642\n",
400-
"P,2022-12-20T00:01:50.978400Z,11097,0.306\n",
401-
"P,2022-12-20T00:01:55.968400Z,11596,0.106\n",
402-
"P,2022-12-20T00:02:06.428400Z,12642,0.342\n",
403-
"P,2022-12-20T00:02:20.758400Z,14075,0.108\n",
404-
"P,2022-12-20T00:02:23.068400Z,14306,0.292\n",
405-
"P,2022-12-20T00:02:30.058400Z,15005,0.279\n"
396+
"phase,time,confidence\n",
397+
"P,2022-12-20T00:01:40.038400Z,0.327\n",
398+
"P,2022-12-20T00:01:41.648400Z,0.789\n",
399+
"P,2022-12-20T00:01:45.568400Z,0.642\n",
400+
"P,2022-12-20T00:01:50.978400Z,0.306\n",
401+
"P,2022-12-20T00:01:55.968400Z,0.106\n",
402+
"P,2022-12-20T00:02:06.428400Z,0.342\n",
403+
"P,2022-12-20T00:02:20.758400Z,0.108\n",
404+
"P,2022-12-20T00:02:23.068400Z,0.292\n",
405+
"P,2022-12-20T00:02:30.058400Z,0.279\n"
406406
]
407407
}
408408
],
@@ -421,7 +421,7 @@
421421
"# Write header\n",
422422
"with open(output_file, 'w', newline='') as f:\n",
423423
" writer = csv.writer(f)\n",
424-
" writer.writerow(['phase', 'time', 'index', 'confidence'])\n",
424+
" writer.writerow(['phase', 'time', 'confidence'])\n",
425425
"\n",
426426
" for phase_idx, phase_label in enumerate(['P', 'S']):\n",
427427
" probs = pred_unwrapped[phase_idx, :]\n",
@@ -432,7 +432,7 @@
432432
" for peak_idx in peaks:\n",
433433
" peak_time = starttime + peak_idx / tr.stats.sampling_rate\n",
434434
" confidence = probs[peak_idx]\n",
435-
" writer.writerow([phase_label, peak_time, peak_idx,f'{confidence:.3f}'])\n",
435+
" writer.writerow([phase_label, peak_time,f'{confidence:.3f}'])\n",
436436
"\n",
437437
"! head detections*"
438438
]

0 commit comments

Comments
 (0)