Skip to content

support for saving and loading pnets and vnets#40

Merged
GeminiLight merged 1 commit intoGeminiLight:mainfrom
reills:save-load-networks
May 16, 2025
Merged

support for saving and loading pnets and vnets#40
GeminiLight merged 1 commit intoGeminiLight:mainfrom
reills:save-load-networks

Conversation

@reills
Copy link
Copy Markdown
Contributor

@reills reills commented May 16, 2025

Hey @GeminiLight ,

Congrats on releasing version 1.0! It looks really good and is very clean. One thing that's been helpful for me is being able to save and load p_net.gml, v_net.gml files so I can better debug and investigate.

In the PR, I added config variables in main.yaml to allow for that. They do:
if_save_pnet: if true, save pnet to the save_root_dir under the generated name.
if_save_vnet: if true, save the vnets to the save_root_dir under the generated name
if_load_pnet: if true, load the pnet from the save root with the generated name
if_load_vnet: if true, load the vnet from the save root with the generated name

Load vnet is cached after the first run so that for the following runs it is not regenerated. Also, since the vnet is generated on reset I figured maybe it might be useful to save only the first generated vnet. Not sure if this is what you had in mind for how a save/load flow would look like, but that seemed most practical to me.

I tried to keep the changes minimal and non-intrusive. Let me know if this seems useful and I’m happy to make updates :)

@GeminiLight
Copy link
Copy Markdown
Owner

Hi @reills

Thank you so much for your positive feedback and for implementing these updates!

These new features you've added are super helpful, particularly in saving and loading datasets. I’ve gone through the PR and tested the features—it all looks great! I’ll go ahead and merge this now, and if needed, make any adjustments in future updates.

At the moment, I’m working on adding more tests, refining the documentation, and polishing the benchmarking paper to make Virne even easier to use and contribute to.

Thanks again for your great contribution!

@GeminiLight GeminiLight merged commit 84e47aa into GeminiLight:main May 16, 2025
1 check passed
@reills
Copy link
Copy Markdown
Contributor Author

reills commented May 19, 2025

really love this project! thanks for all the time you have spent on it.

luismomm2110 pushed a commit to luismomm2110/virne that referenced this pull request Jan 3, 2026
support for saving and loading pnets and vnets
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