-
Notifications
You must be signed in to change notification settings - Fork 21
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
Select zone from inputs #118
Conversation
Pipe map still will have type error if we input zone list in global settings using strings, cause in model part (file h2_pipeline.jl) we need to use Zone column in pipe map to match pipeline flow term. We should discuss how to design this input term and guide user to do like this. Using strings to represent zones is more comfortable for users cause this's meanful. |
Hi @Betristor, these look like good additions. I will have time to test them properly on Thursday, so will do the review for this and issue #117 then. |
This branch selects specific zones from |
@RuaridhMacd Breaking changes include 1. choose zones set from settings (list of string); 2. use start zone and end zone to denote a transmission line or pipeline. This branch doesn't contain modifications in truck route so this should be handled before truck revision. |
|
@RuaridhMacd I tested a continuous case with Zones = ["z1", "z3"], it worked out. |
@RuaridhMacd As for the second task, I think based on the current code development, it will cost more convenience to set a default action when zones list is left none. Here are my thoughts and reasons.
But there do exist some other cases where zone set is pretty large and many zones should be included like hundred of zones need to be listed, quite annoying for users, making a "select all" option welcome. But still the zone set need to be known by the model. Previously we construct a matrix containg all zones and is sparse. It's useful when zone set is small, while inconvenient under the assumption that zone set is large. Regarding all these, I think a "select all" option will be a new feature we need but I may not implement now. (Honestly, I have not come up with a good way to store and access zone list to be compatible with the way Genx took and the way I adopted to construct the spatial matrix.) |
Hi @Betristor That looks good for tasks 1 and 3. I'm happy to use strings for the zone names. It looks like we have more work to do on task 2. I like the idea of having a default action which selects all zones because it avoids issues for users with existing simulations. |
@RuaridhMacd Yeah, I. agree with that. I think the main idea we need to discuss is how to design spatial matrix inputs for transmission lines in Genx, pipeline map and truck routes for hydrogen. Based on a widely accepted way of input, we could find out some way to implement zone selection feature with a default action. Temporarily, I could access zone list from the inputs as a pre-check to save users' trouble when zone list is left none, which means select all zones from the inputs. To filter zones when loading inputs is not only helpful when a subset of zones is needed, but also we could use it as some kind of checks to ensure users' inputs are in match in spatial aspect. |
|
@RuaridhMacd Mac, I enumerated all zones from power transmission lines and hydrogen pipelines to include all zones if no zones entry is provided (no zones entry or empty list). The function is implemented in |
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@RuaridhMacd I've reviewed all changes from main, the modifications won't affect existing code. And as the author of this PR, I can't approve it, but I think it's ready to go.
Thanks @Betristor . I've just merged it. |
Previously we need to create another folder with data to select zone and then create such scenario. With zone selection feature, we could control such behavior in global_model_settings file.