-
Notifications
You must be signed in to change notification settings - Fork 15
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
preprocess.py script does not create subset entries if default values are used #68
Comments
I note that in the fast code, the modex sets are not created for zero-valued entries. |
Hi @willu47, I don't think I quite understand the issue. The script creates subsets in 'MODExTECHNOLOGYperFUELin |
Following on from that, are there cases when we'd need subsets produced for zero valued combinations? |
I don't think that's the case? For the momani code (which I haven't tested), then line 156 writes to output_table, but doesn't seem to be used later. I see now checks for the values of output and input activity ratios. For the otoole code, I've added these in #69.
No, we never need subsets for zero valued combinations. This issue is that because there was no check of zero values, it created empty subsets (which was confusing). The main breaking error was the problem of emission sets. |
Ah, I figured out what's causing this issue. I had removed a line of code as part of an earlier bug fix that introduced this new bug. The script is now fixed, tested, and pushed up to the repo (fe98533) Thanks @willu47. |
When using the preprocess.py script on a datafile which has been converted using otoole, we found that subsets were not being generated for entries in
InputActivityRatio
andOutputActivityRatio
whose value is equal to the default value (zero in most cases). This causes an error downstream when using glpsol to create the model as there are inconsistent subsets.In my mind - if
InputActivityRatio
andOutputActivityRatio
are zero, then the equations should not be generated anyway - the technologies will not consume or produce anything and can reduce to zero.On the other hand, if we need subsets produced for zero valued combinations, then how to make this robust?
I'm not sure if this is something that should be address in i) the model formulation ii) otoole iii) our model definition
The text was updated successfully, but these errors were encountered: