Skip to content

Mainfunc#33

Open
anastassiavybornova wants to merge 2 commits intomainfrom
mainfunc
Open

Mainfunc#33
anastassiavybornova wants to merge 2 commits intomainfrom
mainfunc

Conversation

@anastassiavybornova
Copy link
Member

Description

this solves #32 (GrowBikeNet > growbikenet) and contains a first draft as basis for #23 and #29 (main growbikenet function). Still a couple of open design choices TBD. No docs/tests added yet.

Related Issue

Fixes #(issue number)

Type of Change

  • 🐛 Bug fix (non-breaking change that fixes an issue)
  • ✨ New feature (non-breaking change that adds functionality)
  • 💥 Breaking change (fix or feature that would cause existing functionality to change)
  • 📝 Documentation update
  • 🧹 Code refactor (no functional changes)
  • ✅ Test update

How Has This Been Tested?

  • Unit tests
  • Integration tests
  • Manual testing

Test configuration:

  • OS: macOS

Screenshots (if applicable)

Checklist

  • My code follows the project's style guidelines
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have updated the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix/feature works
  • New and existing tests pass locally

Additional Notes

none

@anastassiavybornova anastassiavybornova self-assigned this Mar 5, 2026
@anastassiavybornova anastassiavybornova added the enhancement New feature or request label Mar 5, 2026
Copy link
Member

@Manuel-Knepper Manuel-Knepper left a comment

Choose a reason for hiding this comment

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

Is this just GitHub being weird, or did you not actually rename the 'GrowBikeNet' directory to 'growbikenet'?

@mszell
Copy link
Member

mszell commented Mar 6, 2026

Is this just GitHub being weird, or did you not actually rename the 'GrowBikeNet' directory to 'growbikenet'?

Same for me. I think the folder still needs to be renamed.

" \"bike\": 2\n",
" }\n",
"\n",
" create_plots(routed_edges_gdf,seed_points_snapped,streetcolor,edgecolor,seedcolor,lws)\n",
Copy link
Member

Choose a reason for hiding this comment

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

Plots are being created even if export_plots is FALSE, if export_video is TRUE. Add an if clause to check for export_plots

"metadata": {},
"outputs": [],
"source": [
"def run_growbikenet(\n",
Copy link
Member

@mszell mszell Mar 6, 2026

Choose a reason for hiding this comment

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

What is the reason for calling it run_growbikenet and not just growbikenet? "grow" is already the thing to do and an imperative, and "run_" seems to make it more complicated/unnatural, to me at least.

I imagine in practice it would be used like this:

import growbikenet as gbn
a_edges = gbn.growbikenet(
    "Manhattan",
    proj_crs = '3857',
    export_plots = True,
    export_video = True
)

I would suggest to do it like this, but open to discussion.

Copy link
Member

Choose a reason for hiding this comment

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

I realize this would need an _api.py so we dont need to load .functions. Much cleaner I think. Like here: https://github.com/NERDSITU/superblockify/blob/main/superblockify/_api.py

@anastassiavybornova
Copy link
Member Author

@Manuel-Knepper my blessings to you for finishing this up :)

next steps before merging (in hopefully meaningful order):

  • check the folder de-capitalization to growbikenet
  • rename main func to growbikenet
  • add different ranking methods option if-else to mainfunc
  • write docstring for main func
  • insert assertions for valid user input for all parameters
  • write tests for main func
  • (api file like in superblockify to expose gbn funcs? - can potentially be a separate issue for later)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants