Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Secondary locations #41

Merged
merged 43 commits into from
Sep 17, 2024
Merged

Secondary locations #41

merged 43 commits into from
Sep 17, 2024

Conversation

Hussein-Mahfouz
Copy link
Collaborator

  • Assigning secondary locations using pam
  • Restructuring scripts

@@ -229,7 +230,7 @@ def plot_desire_lines(
bin_size: int,
boundaries: gpd.GeoDataFrame,
sample_size: Optional[int] = None,
save_dir: Optional[str] = None,
save_dir: str | None | Path = None,
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How do I use pathlib for this now? Do we need to edit the scripts? Currently, this is how we pass the save_dir: link

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's since we added acbm.root_path (as this is a Path) and when this combines with a str (with the /) it also returns a Path.

Copy link
Collaborator

@sgreenbury sgreenbury Sep 16, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah good point on the other scripts. I updated the other save_dir in plots.py ce523a8 since also called with Path arg in the scripts. It might be worth adding a type checker at some point for this to the pre-commit/actions too (e.g. mypy/pyright) - I'll open an issue (see #47).

@Hussein-Mahfouz Hussein-Mahfouz merged commit 9f36bf3 into main Sep 17, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants