Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Liu Dezi
csst_msc_sim
Commits
0d59783b
Commit
0d59783b
authored
Jun 08, 2021
by
Zhang Xin
Browse files
fix spec sim bug
parent
d5059d30
Changes
2
Show whitespace changes
Inline
Side-by-side
ObservationSim/Instrument/Chip/Chip.py
View file @
0d59783b
...
@@ -312,7 +312,7 @@ class Chip(FocalPlane):
...
@@ -312,7 +312,7 @@ class Chip(FocalPlane):
BoolDeadPix
=
False
BoolDeadPix
=
False
# Add sky background
# Add sky background
if
sky_map
==
None
:
if
sky_map
is
None
:
sky_map
=
filt
.
getSkyNoise
(
exptime
=
self
.
exptime
)
sky_map
=
filt
.
getSkyNoise
(
exptime
=
self
.
exptime
)
elif
img
.
array
.
shape
!=
sky_map
.
shape
:
elif
img
.
array
.
shape
!=
sky_map
.
shape
:
raise
ValueError
(
"The shape img and sky_map must be equal."
)
raise
ValueError
(
"The shape img and sky_map must be equal."
)
...
...
ObservationSim/ObservationSim.py
View file @
0d59783b
...
@@ -218,7 +218,7 @@ class Observation(object):
...
@@ -218,7 +218,7 @@ class Observation(object):
pointing_ID
=
pointing_ID
,
pointing_ID
=
pointing_ID
,
timestamp_obs
=
timestamp_obs
,
timestamp_obs
=
timestamp_obs
,
pointing_type
=
pointing_type
,
pointing_type
=
pointing_type
,
sky_map
=
sky_map
)
sky_map
=
sky_map
,
tel
=
self
.
tel
)
if
pointing_type
==
'MS'
:
if
pointing_type
==
'MS'
:
datetime_obs
=
datetime
.
fromtimestamp
(
timestamp_obs
)
datetime_obs
=
datetime
.
fromtimestamp
(
timestamp_obs
)
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment