Don't remove generated files in learn notebook

jupyter
Jeff Moe 2022-09-11 21:03:04 -06:00
parent f416ba7d29
commit 097fff7f61
2 changed files with 33 additions and 27 deletions

View File

@ -12,7 +12,9 @@
"# Two FITS files will be acquired live from the attached video source.\n",
"# Each layer in the generated FITS file to be displayed.\n",
"# Each step in process_new.py to be performed and displayed,\n",
"# including output text files."
"# including output text files.\n",
"#\n",
"# Only works for OpenCV (/dev/video*) cameras at present"
]
},
{
@ -297,7 +299,9 @@
},
{
"cell_type": "markdown",
"metadata": {},
"metadata": {
"tags": []
},
"source": [
"Capture images"
]
@ -306,6 +310,9 @@
"cell_type": "code",
"execution_count": null,
"metadata": {
"jupyter": {
"source_hidden": true
},
"tags": []
},
"outputs": [],
@ -675,30 +682,30 @@
"# calfname = os.path.join(file_dir, \"test.fits\")\n",
"\n",
" # XXX REMOVE WITH A HAMMER ALL GENERATED FILES:\n",
" fdats = glob.glob(\"data/obs/jupyter/*.dat\", recursive=False)\n",
" for fdat in fdats:\n",
" print(\"Removing\", fdat)\n",
" os.remove(fdat)\n",
" fpngs = glob.glob(\"data/obs/jupyter/*.png\", recursive=False)\n",
" for fpng in fpngs:\n",
" print(\"Removing\", fpng)\n",
" os.remove(fpng)\n",
" fcals = glob.glob(\"data/obs/jupyter/*.cal\", recursive=False)\n",
" for fcal in fcals:\n",
" print(\"Removing\", fcal)\n",
" os.remove(fcal)\n",
" fcats = glob.glob(\"data/obs/jupyter/*.cat\", recursive=False)\n",
" for fcat in fcats:\n",
" print(\"Removing\", fcat)\n",
" os.remove(fcat)\n",
" fcsvs = glob.glob(\"data/obs/jupyter/*.csv\", recursive=False)\n",
" for fcsv in fcsvs:\n",
" print(\"Removing\", fcsv)\n",
" os.remove(fcsv)\n",
" ftests = glob.glob(\"data/obs/jupyter/test.fits\", recursive=False)\n",
" for ftest in ftests:\n",
" print(\"Removing\", ftest)\n",
" os.remove(ftest)\n",
" #fdats = glob.glob(\"data/obs/jupyter/*.dat\", recursive=False)\n",
" #for fdat in fdats:\n",
" # print(\"Removing\", fdat)\n",
" # os.remove(fdat)\n",
" #fpngs = glob.glob(\"data/obs/jupyter/*.png\", recursive=False)\n",
" #for fpng in fpngs:\n",
" # print(\"Removing\", fpng)\n",
" # os.remove(fpng)\n",
" #fcals = glob.glob(\"data/obs/jupyter/*.cal\", recursive=False)\n",
" #for fcal in fcals:\n",
" # print(\"Removing\", fcal)\n",
" # os.remove(fcal)\n",
" #fcats = glob.glob(\"data/obs/jupyter/*.cat\", recursive=False)\n",
" #for fcat in fcats:\n",
" # print(\"Removing\", fcat)\n",
" # os.remove(fcat)\n",
" #fcsvs = glob.glob(\"data/obs/jupyter/*.csv\", recursive=False)\n",
" #for fcsv in fcsvs:\n",
" # print(\"Removing\", fcsv)\n",
" # os.remove(fcsv)\n",
" #ftests = glob.glob(\"data/obs/jupyter/test.fits\", recursive=False)\n",
" #for ftest in ftests:\n",
" # print(\"Removing\", ftest)\n",
" # os.remove(ftest)\n",
"\n",
" # Set warnings\n",
" warnings.filterwarnings(\"ignore\", category=UserWarning, append=True)\n",

View File

@ -1,3 +1,2 @@
ipympl
jupyterlab
p2j