Skip to content

SP-3027: fix NB 105 6 custom coadds#136

Open
shenmingfu wants to merge 4 commits intomainfrom
tickets/SP-3027
Open

SP-3027: fix NB 105 6 custom coadds#136
shenmingfu wants to merge 4 commits intomainfrom
tickets/SP-3027

Conversation

@shenmingfu
Copy link
Copy Markdown
Contributor

No description provided.

@review-notebook-app
Copy link
Copy Markdown

Check out this pull request on  ReviewNB

See visual diffs & provide feedback on Jupyter Notebooks.


Powered by ReviewNB

@shenmingfu shenmingfu requested a review from athornton April 7, 2026 22:43
Copy link
Copy Markdown
Collaborator

@athornton athornton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine. You might want to make sure that you don't do any of this if the os.getenv() comes back None, but at least in that case making the path will fail with an error and you won't do anything weird with the unlink call.

I'll again reiterate for the record that SCRATCH_DIR is only going to be set at IDF RSP instances, and specifically that it will not work at USDF.

No opinion on the mtv->image change, but I presume it does what you mean it to.

@athornton
Copy link
Copy Markdown
Collaborator

athornton commented Apr 8, 2026

The removal happens at "32 05 * * 0" # Sunday morning, 12:32 AM (UTC-5) for data.lsst.cloud. So late Saturday on the West Coast, early Sunday East Coast, 5:32 in UTC. 12:27 AM for int, 12:19 for dev.

@shenmingfu
Copy link
Copy Markdown
Contributor Author

@athornton Thank you for your comments and review!

You might want to make sure that you don't do any of this if the os.getenv() comes back None

I guess you mean $SCRATCH_DIR does not exist and then os.getenv("SCRATCH_DIR") gives None. In that case Path() will return an error. Does that mean on RSP during the cleaning time even the variable $SCRATCH_DIR gets removed? I just added an if case there to check if it's None. In the description above the cell I mentioned do not run this step during the cleaning time.

I'll again reiterate for the record that SCRATCH_DIR is only going to be set at IDF RSP instances, and specifically that it will not work at USDF.

Yes, we mentioned that this is for RSP (in the description and at the beginning of the notebook).

No opinion on the mtv->image change, but I presume it does what you mean it to.

Yeah mtv is an old command, and we updated it to image.

So late Saturday on the West Coast, early Sunday East Coast, 5:32 in UTC

Thanks. I changed the text to "around noon Sunday Pacific time".

"if scratch_dir is not None:\n",
" scratch_path = Path(scratch_dir)\n",
"\n",
"if not scratch_path.exists():\n",
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If SCRATCH_DIR wasn't set then scratch_path will not be defined.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, that will throw an error. But I mentioned in the description text that the user should not run this step (and following steps) during / right before the cleaning time. And the undefined scratch_path also prevents the user from running further steps (especially writing large files to local space). So I think that's fine.
Please let me know if you have any other comments.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants