-
Notifications
You must be signed in to change notification settings - Fork 40
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
Applies TotalInvTracker and (R,Q)/(s,S) inventory policies to storage #574
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
nuclearkatie
changed the title
Applies TotalInvTracker and (R,Q) inventory policy to storage
Applies TotalInvTracker and (R,Q)/(s,S) inventory policies to storage
Jan 31, 2024
gonuke
requested changes
Feb 6, 2024
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.
This looks pretty clean - looking forward to reviewing it with a working kernel.
Co-authored-by: Paul Wilson <paul.wilson@wisc.edu>
nuclearkatie
force-pushed
the
R_Q_inventory
branch
from
February 7, 2024 17:09
074a61f
to
763c9f1
Compare
gonuke
approved these changes
Feb 7, 2024
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.
Thanks @nuclearkatie - nice to see this implemented
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Relies on Cyclus PR cyclus#1646. Until that one is merged, this one cannot be merged. They should be merged together if possible
This PR implements the new
TotalInvTracker
from cyclus#1646 into Storage, which provides an agent-wide inventory limitation and is required as part of initializing the buy policy.This fixes the janky way that Storage was previously calculating an agent-wide limitation! Now, the
max_inv_size
is applied to the whole facility through the use ofTotalInvTracker
. Closes #554, Storage no longer needs to change the capacity of Resource Buffers ever time stepThis also adds two variables
reorder_point
when total facility inventory is above this point, no new demands will be made. At or below this point, the agent will request materialreorder_quantity
when applicable, agent will request exactly this amount. It will make an exclusive demand for exactly this valueWhen
reorder_point
is used alone, it results in a (s,S) or min/max inventory policy. When the buffer inventory is belowreorder_point
, buypol tries to buy up to a full facility (max_inv_size
, which is facility-wide). When used withreorder_quantity
, this is a (R,Q) buy pol where the facility makes a single exclusive request of sizereorder_quantity
once belowreorder_point
. In both cases, when the inventory is abovereorder_point
, no requests are madeCloses #577, closes #578