Skip to content

Commit

Permalink
towards scaling for paper fig
Browse files Browse the repository at this point in the history
  • Loading branch information
jsta committed Apr 10, 2024
1 parent 992e379 commit 28366bb
Show file tree
Hide file tree
Showing 4 changed files with 47 additions and 1 deletion.
11 changes: 11 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -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
34 changes: 34 additions & 0 deletions docs/paper_fig/Makefile
Original file line number Diff line number Diff line change
@@ -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
3 changes: 2 additions & 1 deletion hydropop/dev/end_to_end_new.py
Original file line number Diff line number Diff line change
Expand Up @@ -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(
Expand Down
Empty file added results/.gitkeep
Empty file.

0 comments on commit 28366bb

Please sign in to comment.