Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
27 commits
Select commit Hold shift + click to select a range
ffb365e
Phase 1 implementation: make create_products.py more general
MBARIMike Apr 6, 2026
83673e9
Initial implementation of Phase 2.
MBARIMike Apr 7, 2026
64e4e74
Implement Phase 3 — HTML file generation
MBARIMike Apr 7, 2026
f7419f6
Add per-log plots.
MBARIMike Apr 7, 2026
3339349
Improve the titles.
MBARIMike Apr 7, 2026
11411a6
Remove ".dmr" from the dodsurlstirngs.
MBARIMike Apr 8, 2026
407e5c9
Add STOQS permalink to LRAUV deployment HTML index
MBARIMike Apr 10, 2026
bee7ee3
Add _plot_log_file_boundaries() to be used by lrauv_deployment_plots.py.
MBARIMike Apr 10, 2026
2ef7264
Spiff up the deployment plot with local midnight labels, etc.
MBARIMike Apr 10, 2026
a140886
Update GITHUB values.
MBARIMike Apr 10, 2026
68cbbd3
Archive the Deployment plot(s) and .html file.
MBARIMike Apr 10, 2026
78bef7b
Update EXPECTED_MD5_GITHUB, again!
MBARIMike Apr 10, 2026
78e0426
Add --update_ssds_provenance and _submit_provenance().
MBARIMike Apr 10, 2026
f87791a
Add resourcetype_names to the .png and .html Resources.
MBARIMike Apr 10, 2026
4dcbfc4
Update EXPECTED_MD5_GITHUB, AGAIN.
MBARIMike Apr 10, 2026
078e65f
EXPECTED_MD5_GITHUB keeps alternating.
MBARIMike Apr 10, 2026
6c409de
Add time-range and batch execution options to lrauv_deployment_plots.py
MBARIMike Apr 10, 2026
9de6b12
Update EXPECTED_MD5_GITHUB.
MBARIMike Apr 10, 2026
cc82510
Disable EXPECTED_MD5_GITHUB.
MBARIMike Apr 10, 2026
33b79fd
WIP on creating web pages for Quick Look Plots.
MBARIMike Apr 11, 2026
bde1403
Write old-school .html page for each .png image.
MBARIMike Apr 13, 2026
3cbdf98
Add per-log links to the images.
MBARIMike Apr 13, 2026
9e53fa5
Copy new per-image .html files to the archive and record the provenance.
MBARIMike Apr 13, 2026
96bb3f9
Do not record an output Datacontainer for lruav_deployment_plots.py P…
MBARIMike Apr 13, 2026
4404361
Remove the CSS heavy index .html page generation.
MBARIMike Apr 13, 2026
455813a
Add footer stating what created the page.
MBARIMike Apr 13, 2026
8314b4e
Add and test --force option.
MBARIMike Apr 13, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 21 additions & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -467,7 +467,27 @@
// Test --update_ssds_provenance with a short log_file
//"args": ["-v", "1", "--log_file", "ahi/missionlogs/2025/20250128_20250131/20250131T051404/202501310514_202501310535.nc4", "--update_ssds_provenance"]
// Test ahi mission that has Backseat Planktivore data with --update_ssds_provenance
"args": ["-v", "1", "--log_file", "ahi/missionlogs/2025/20250414_20250418/20250415T040019/202504150400_202504152346.nc4", "--update_ssds_provenance"]
//"args": ["-v", "1", "--log_file", "ahi/missionlogs/2025/20250414_20250418/20250415T040019/202504150400_202504152346.nc4", "--update_ssds_provenance"]
// Make per log file .html files to test with lrauv_deployment_plots and --update_ssds_provenance
"args": ["-v", "1", "--auv_name", "ahi", "--start", "20251022T000000", "--end", "20251024T000000", "--update_ssds_provenance", "--clobber"]
},
{
"name": "lrauv_deployment_plots",
"type": "debugpy",
"request": "launch",
"program": "${workspaceFolder}/src/data/lrauv_deployment_plots.py",
"console": "integratedTerminal",
// ahi planktivore deployment April 2025
//"args": ["-v", "1", "--dlist", "ahi/missionlogs/2025/20250414_20250418.dlist"]
// tethys CANON September 2012 (classic test case)
//"args": ["-v", "1", "--dlist", "tethys/missionlogs/2012/20120908_20120920.dlist"]
// ahi planktivore deployment April 2025 add --update_ssds_provenance
//"args": ["-v", "1", "--dlist", "ahi/missionlogs/2025/20250414_20250418.dlist", "--update_ssds_provenance"]
// Test time range of DeploymentPlots with ahi planktivore deployment April 2025
//"args": ["-v", "1", "--auv_name", "ahi", "--start", "20251001", "--end", "20251231", "--update_ssds_provenance", "--force"]
// Test web page building with a short deployment
//"args": ["-v", "1", "--dlist", "ahi/missionlogs/2025/20251022_20251024.dlist", "--update_ssds_provenance"]
"args": ["-v", "1", "--last_n_days", "10", "--update_ssds_provenance", "--force"]
},

]
Expand Down
2 changes: 2 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ dependencies = [
"cmocean>=4.0.3",
"coards>=1.0.5",
"contextily>=1.7.0",
"dask>=2024.1.0",
"datashader>=0.18.1",
"defusedxml>=0.7.1",
"gitpython>=3.1.44",
Expand All @@ -20,6 +21,7 @@ dependencies = [
"ipympl>=0.9.7",
"jupyter>=1.1.1",
"jupyter-bokeh>=4.0.5",
"lzstring>=1.0.4",
"netcdf4>=1.7.2",
"numpy>=2.2.6",
"pandas>=2.2.0",
Expand Down
52 changes: 52 additions & 0 deletions src/data/archive.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,6 +294,58 @@ def copy_to_LRAUV(self, log_file: str, freq: str = FREQ) -> None: # noqa: C901,
src_file.name,
)

def copy_lrauv_deployment(self, deployment_dir: Path, plot_name_stem: str) -> None:
"""Copy LRAUV deployment plots and HTML index to the LRAUV archive volume.

Mirrors *deployment_dir* under ``/Volumes/LRAUV``, creating the
destination directory if needed. Copies:
- all ``{plot_name_stem}_*.png`` deployment plot files
- the ``{plot_name_stem}.html`` index file

Args:
deployment_dir: Local directory that contains the generated files
(e.g. ``BASE_LRAUV_PATH/vehicle/missionlogs/YYYY/dlist_dir/``).
plot_name_stem: Stem used to name the plots and HTML file.
"""
try:
rel = deployment_dir.relative_to(BASE_LRAUV_PATH)
except ValueError:
self.logger.warning(
"deployment_dir %s is not under BASE_LRAUV_PATH %s; skipping archive",
deployment_dir,
BASE_LRAUV_PATH,
)
return
dst_dir = Path(LRAUV_VOL) / rel
try:
dst_dir.stat()
except FileNotFoundError:
self.logger.warning("%s not found; is %s mounted?", dst_dir, LRAUV_VOL)
return
dst_dir.mkdir(parents=True, exist_ok=True)
candidates = list(deployment_dir.glob(f"{plot_name_stem}_*.png"))
candidates.append(deployment_dir / f"{plot_name_stem}.html")
candidates.extend(deployment_dir.glob(f"{plot_name_stem}_*.html"))
for src_file in candidates:
if not src_file.exists():
self.logger.debug("Source file not found, skipping: %s", src_file)
continue
dst_file = dst_dir / src_file.name
if self.clobber:
if dst_file.exists():
self.logger.info("Removing %s", dst_file)
dst_file.unlink()
shutil.copyfile(src_file, dst_file)
self.logger.info("copyfile %s %s done.", src_file.name, dst_dir)
elif dst_file.exists():
self.logger.info(
"%-60s exists, but is not being archived because --clobber is not specified.",
src_file.name,
)
else:
shutil.copyfile(src_file, dst_file)
self.logger.info("copyfile %s %s done.", src_file.name, dst_dir)

def process_command_line(self):
"""Process command line arguments using shared parser infrastructure."""
# Use shared parser with archive-specific additions
Expand Down
Loading
Loading