-
Notifications
You must be signed in to change notification settings - Fork 4
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
Update for SCS-106 change and new power commands #41
Conversation
I'm getting some regression test failures--I'll be checking them to see what's causing them. |
You should be getting errors whenever an SCS-107 was run. This is the crux of the change - SCS-107 calls SCS-106 and 106 now leaves 3 FEP's on, whereas before it left no FEP's on. So the DPA temps should be very different as well as FEP count. Here is an example(circa 355:10): |
self.bs_cmds = bs_cmds | ||
|
||
# Clip commands to tbegin | ||
bs_cmds = bs_cmds[bs_cmds['date'] > tbegin] |
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.
So in the old version we were clipping commands to tbegin
. Based on your changes, do we not want to do this anymore, or is in being done in backstop_history
now?
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.
Backstop history was supposed to do that but the ~30 minute backoff caused it to backchain one
extra Continuity load and, without the clipping, that caused the kadi_states.get_states to return the time-disrupted result.
Putting the line back in and clipping the bs_cmds seems to have fixed it.
I will re-run the regression tests and check the FEP plot to be sure.
Thanks
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.
Ok--sounds good. Probably a good idea in the future to revisit the -5 element backoff and find something to do that maybe makes more sense (or at least is easier to understand)
I have an update that I'd like to add to this PR, which should be a no-op--it only clears up the role of the I've added it to my own branch--you can see it here: If you want to add it, let me know and we can just push this commit here. |
Sure lets include this update in this release. I'll need a line or two for the release notes. |
acis_thermal_check/main.py
Outdated
@@ -1067,10 +1072,10 @@ def make_validation_plots(self, tlm, model_spec, outdir, run_start): | |||
f.write(quant_table) | |||
f.close() | |||
|
|||
# If run_start is specified this is likely for regression testing | |||
# If self.write_pickle is specified this is likely for regression testing |
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.
Check: is "specified" or is True?
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.
is True
, yes
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.
Actually "specified" is a much better comment.
Comments are not supposed to replicate/repeat the code: the reader can see how the if statement works. Comments are there to tell the reader what the intent is....to explain what's going on so that the reader does not have to waste time figuring out what's going on.
As a simple example, suppose you are incrementing x:
x +=1
The following is a useless comment:
# Increment x
x +=1
Anyone can see that x is being incremented. The comment provides no additional information.
The reader does not know why you are doing that.
But this is a more useful comment:
# Point to the next item in the star chart list.
x+=1
"specified" is better than True. But it can be made better still. I changed it to:
# self.write_pickle is set to the value of the --run-start command
# line argument; either a DOY date string or None (if the argument
# was not specified). If a DOY date, this model run is likely for regression
# testing or other debugging. In that case write out the full
# predicted and telemetered dataset as a pickle.
Anyone trying to figure out what we did now knows how self.write_pickle gets set, why it is set
and the intent of the block of code.
acis_thermal_check/state_builder.py
Outdated
@@ -45,7 +45,7 @@ def get_validation_states(self, datestart, datestop): | |||
Parameters | |||
---------- | |||
datestart : string | |||
The start date to grab states afterward. | |||
The start date to grab states afterward.builder_class |
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.
missing carriage return before builder_class?
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.
No just some text that wasn't there in the original. It's been removed.
acis_thermal_check/state_builder.py
Outdated
states from the review load backstop file and all the | ||
states between the latest telemetry data and the beginning | ||
commands from the review load backstop file and all the | ||
commands between the latest telemetry data and the beginning | ||
of that review load backstop file. | ||
|
||
The Review Backstop commands already obtained. | ||
Telemtry from 21 days back to the latest in Ska obtained. |
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.
Telemetry misspelled
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.
Fixed
acis_thermal_check/state_builder.py
Outdated
# Convert backstop commands from a list of dict to a CommandTable and | ||
# store in self. | ||
bs_cmds = kadi.commands.CommandTable(bs_cmds) | ||
# Ask Backstop History to assemble the history for this loa |
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.
"loa" --> "load"
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.
Fixed
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.
Looks ok to me Gregg. I flagged some small typos / potential wording issues in your description, but nothing in the code raised any flags with me.
Hey Gregg,
Thanks for your explanation. I'm reacting to this:
self.write_pickle = args.run_start is not None
from which I infer that write_pickle is True/False. In this case, I would
think a value could be *False* but to me that's still specified, as opposed
to empty / None which is what I would take from "unspecified". Now, you
have:
# self.write_pickle is set to the value of the --run-start command
but I don't think that's the case - it's T/F, right?
…On Fri, Oct 15, 2021 at 11:28 AM Gregg140 ***@***.***> wrote:
***@***.**** commented on this pull request.
------------------------------
In acis_thermal_check/main.py
<#41 (comment)>
:
> @@ -1067,10 +1072,10 @@ def make_validation_plots(self, tlm, model_spec, outdir, run_start):
f.write(quant_table)
f.close()
- # If run_start is specified this is likely for regression testing
+ # If self.write_pickle is specified this is likely for regression testing
Actually "specified" is a much better comment.
Comments are not supposed to replicate/repeat the code: the reader can see
how the if statement works. Comments are there to tell the reader what the
intent is....to explain what's going on so that the reader does not have to
waste time figuring out what's going on.
As a simple example, suppose you are incrementing x:
x +=1
The following is a useless comment:
*# Increment x*
x +=1
Anyone can see that x is being incremented. The comment provides no
additional information.
The reader does not know why you are doing that.
But this is a more useful comment:
*# Point to the next item in the star chart list.*
x+=1
"specified" is better than True. But it can be made better still. I
changed it to:
# self.write_pickle is set to the value of the --run-start command
# line argument; either a DOY date string or None (if the argument
# was not specified). If a DOY date, this model run is likely for regression
# testing or other debugging. In that case write out the full
# predicted and telemetered dataset as a pickle.
Anyone trying to figure out what we did now knows how self.write_pickle
gets set, why it is set
and the intent of the block of code.
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#41 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ACN5TGKCGRCVWNBBGHPCQT3UHBCAXANCNFSM5FCYKPCQ>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
|
Description
Recently, SCS-106 was updated to leave 3 FEPs on rather than no FEPs on.
SCS-106 is run as part of the SCS-107 sequence.
Therefore thermal model history assembly requires that this change be reflected
in any shutdown: both science-only shutdowns as well as Full Stops. Also, the
ACIS Team recently added new power commands which have to be handled by Backstop History.
These were the drivers for the release of this version of Backstop History.
Several changes had been underway for some time and are incorporated in this release.
Testing
Fixes #