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
Tickets/DM-10848 #1
Conversation
Stop scaling the noise used for fake sources by the amplifier gain as this effect should have been dealt with in ISR
Make the RandomStarFakeSourcesTask able to run with the fake object insertion hooks in the LSST pipeline
Make the RandomGalSimFakesTask able to run with the fake object insertion hooks in the LSST pipeline
Make the PositionGalsimFakes task compatible with the LSST fake object pipeline hooks.
nStars = lsst.pex.config.Field(dtype=int, default=1, | ||
doc="Number of stars to add") | ||
magnitude = lsst.pex.config.Field(dtype=float, default=20.0, | ||
doc="Magnitude of all stars to be added") | ||
margin = lsst.pex.config.Field(dtype=int, default=None, optional=True, | ||
doc="Size of margin at edge that should not be added") | ||
seed = lsst.pex.config.Field(dtype=int, default=0, | ||
seed = lsst.pex.config.Field(dtype=int, default=1, |
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.
Why is the default seed changed to 1?
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.
Simply because the code fails if the seed is zero with an InvalidParameterError with the current stack. As it was just a seed, I figured the value didnt matter
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.
I see. Sometimes I've seed=0 mean use the current time stamp, but I don't know if that is the case with our software. If seed=0 is not allowed, than it probably doesn't matter.
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.
Yeah, this is produced:
lsst.afw.math.Random(seed=0)
---------------------------------------------------------------------------
InvalidParameterError Traceback (most recent call last)
<ipython-input-41-e4860cd80795> in <module>()
----> 1 lsst.afw.math.Random(seed=0)
InvalidParameterError:
File "src/math/Random.cc", line 66, in void lsst::afw::math::Random::initialize()
Invalid RNG seed: 0 {0}
lsst::pex::exceptions::InvalidParameterError: 'Invalid RNG seed: 0'
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.
Changes look good. Only one small question.
No description provided.