From 28366bb9a87f1297818fbb99ef80f294775e35aa Mon Sep 17 00:00:00 2001 From: Jemma Stachelek Date: Wed, 10 Apr 2024 14:57:27 -0600 Subject: [PATCH] towards scaling for paper fig --- .gitignore | 11 +++++++++++ docs/paper_fig/Makefile | 34 ++++++++++++++++++++++++++++++++++ hydropop/dev/end_to_end_new.py | 3 ++- results/.gitkeep | 0 4 files changed, 47 insertions(+), 1 deletion(-) create mode 100644 docs/paper_fig/Makefile create mode 100644 results/.gitkeep diff --git a/.gitignore b/.gitignore index dfd5880..ca374a7 100644 --- a/.gitignore +++ b/.gitignore @@ -144,3 +144,14 @@ cython_debug/ # MacOS *DS_Store + +# Data +results/*.dbf +results/*.cpg +results/*.gpkg +results/*.prj +results/*.shp +results/*.tif +results/*.csv +results/*.shx +data \ No newline at end of file diff --git a/docs/paper_fig/Makefile b/docs/paper_fig/Makefile new file mode 100644 index 0000000..880abbd --- /dev/null +++ b/docs/paper_fig/Makefile @@ -0,0 +1,34 @@ +all: + python hydropop/dev/end_to_end_new.py \ + --pop_breaks -11 -10 -4 0 100 \ + --hthi_breaks -0.01 0.4 0.7 1.01 \ + --path_bounding_box data/roi_small.gpkg \ + --run_name coarse_coarse_small + + python hydropop/dev/end_to_end_new.py \ + --pop_breaks -11 -10 -4 0 100 \ + --hthi_breaks -0.01 0.3 0.55 0.75 0.9 1.01 \ + --path_bounding_box data/roi_small.gpkg \ + --run_name coarse_fine_small + + python hydropop/dev/end_to_end_new.py \ + --pop_breaks -11 -10 -4 -1 1 2 100 \ + --hthi_breaks -0.01 0.4 0.7 1.01 \ + --path_bounding_box data/roi_small.gpkg \ + --run_name fine_coarse_small + + python hydropop/dev/end_to_end_new.py \ + --pop_breaks -11 -10 -4 -1 1 2 100 \ + --hthi_breaks -0.01 0.3 0.55 0.75 0.9 1.01 \ + --path_bounding_box data/roi_small.gpkg \ + --run_name fine_fine_small + +clean: + -@rm ../../results/*.tif + -@rm ../../results/*.cpg + -@rm ../../results/*.dbf + -@rm ../../results/*.gpkg + -@rm ../../results/*.prj + -@rm ../../results/*.shp + -@rm ../../results/*.shx + -@rm ../../results/*.csv \ No newline at end of file diff --git a/hydropop/dev/end_to_end_new.py b/hydropop/dev/end_to_end_new.py index d4bf6c3..b244c3b 100644 --- a/hydropop/dev/end_to_end_new.py +++ b/hydropop/dev/end_to_end_new.py @@ -194,7 +194,8 @@ def end_to_end_new( paths = hut.prepare_export_paths(path_results, run_name) if not overwrite and os.path.exists(paths["hpu_gpkg"]): - print("Requested hpu already exists at:\n" + paths["hpu_gpkg"]) + print("Requested hpu already exists at:\n" + paths["hpu_gpkg"]) + # gpd.read_file(paths["hpu_gpkg"]).columns return None _generate_hpus( diff --git a/results/.gitkeep b/results/.gitkeep new file mode 100644 index 0000000..e69de29