-
Notifications
You must be signed in to change notification settings - Fork 0
U/lynnej/add sim notebook #125
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
Conversation
91e181d to
bc2b4ca
Compare
|
This doesn't replace in any way the prenight simulations, but adds a place where we could check out default options on the fly. |
ehneilsen
left a comment
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.
github doesn't seem to let me comment on individual lines of notebooks anymore, so I guess I put it all here.
Overall, I think this really should be reworked to avoid duplication with the prenight stuff, primarily by extracting code all the code with overlapping functionality and putting it somewhere it could be called by either: the stuff useful here is likely also stuff that would be useful to add to the prenight briefing, and some things here are near duplicates of things already in the prenights. For example, the code for the downtime, DDF availability, and seeing plots could be moved into schedview, and just called in this notebook, so that these plots could be added to the night summary and/or prenight report, and the airmass plot duplicates the altitude & airmass plot in the prenight (but without the hovertool).
The maps at the end are quite close to some of those I was working on last week for a different issue (SP-2518), and will be making a PR for probably next week. (I have them running in a scratch notebook, and am working on getting them into schedview and schedview_notebooks.)
It would be really good if the simulations created this way were added to the simulation database. This is easy if the notebook has write access to the prenight postgresql database, which unfortunately it won't if it's run with TS. It's always been "on my radar" to make a phalanx service to do on-the-fly new prenight simulations, and if all of the simulation creation code in this notebook was in a python function instead of a notebook, that probably wouldn't be that hard: we could inject the credentials to add to the database using the phalanx secrets mechanism.
|
I don't really think you want these simulations added to the prenight database though. Although a lot of them will be simple one-night for the upcoming night outputs (which would just be identical to what you create in the prenight sims, but not as good because it's only one night), someone could make one for five nights .. or start one five nights into the future just because they want to see what might happen on Friday (but it wouldn't be a really good sim, because you'd be missing the four nights of observations between now and Friday). Note that you can also choose a date in the past -- on purpose. This lets you see how close we would have come to what we did, if we knew when we would have been on-sky. The airmass plot is different than the one in schedview, because the grouping and color-coding is quite different. Also note that it is different once you choose a date in the past. We can move some of these ad-hoc plots into schedview .. they really were just testing things that turned out to be kind of useful. I can put in a PR for this kind of crappy downtime plot and the DDF visibility .. I suppose what we can do after that is rework the prenight briefing to include more of this too. |
One of the major problems with the current prenight simulation code is dealing with last minute updates: we need an easier mechanism for someone add new simulations based on updated ts_config_scheduler setups, new ToO stuff, etc. This code could either accomplish that directly (by including code to add a sim to the archive). Or, if it gets extracted from the notebook into real importable python code (probably in |
Plots to compare actual to simulated visits were the intention of the |
|
I am somewhat confused. |
The color coding in |
|
The ToO reading from a pickle doesn't count -- everything in the notebook is a hack to get around the fact that nothing at USDF can access the lsst.scimma.too_alerts topic which only exists at base and summit. The solution to this is just to get this topic into the usdf copy of the EFD. And then the function from lsst-survey-sim works. |
Yeah, it was mostle the ToO stuff I was thinking of. |
I was referring more to SP-2518 (adding maps of more stuff to nightsum) than SP-2517 (adding the McBryde projection maps). |
I've had ambitious thoughts on a DDF plot for a while, something that kind of replicates what the old iObserve macos observing planning app used to do (it doesn't seem to exist anymore) and that I found useful for other projects. It's basically an altitude plots of pointings of interest, much like the DDF visibility plot you have here, but which also represents the proximity to the moon. It would also be useful to mark the times the scheduler has it pre-scheduled, and maybe other stuff. But, a plot with only a little information (e.g. alt) that actually exists is way better than any plot that only exists in my head! |
Adds prenight/run_sim notebook which will run a default simulation and make some plots.
Running on a night in the past will generate a simulation which matches the time the FBS was on-sky.