Skip to content
GitLab
Explore
Projects
Groups
Snippets
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
csst-sims
csst_msc_sim
Commits
dfb71c23
Commit
dfb71c23
authored
11 months ago
by
Fang Yuedong
Browse files
Options
Download
Email Patches
Plain Diff
magnitude ('mag_use_normal') calculations for galaxies and QSOs now is only based on their SEDs
parent
36106f04
release_v3.0
develop
master
milky_way_extinction
revert-914004c1
sls_psf_pca_convolve
v3.3.0
v3.2.1
v3.2.0
v3.1.0
4 merge requests
!30
bug fix for guidance abberation correction
,
!28
bug fix for guidance abberation correction
,
!27
Add Milky Way extinction and extend the range for SED integration
,
!26
update branch sls_psf_pcs_convole
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
catalog/C9_Catalog.py
+16
-2
catalog/C9_Catalog.py
with
16 additions
and
2 deletions
+16
-2
catalog/C9_Catalog.py
+
16
-
2
View file @
dfb71c23
...
...
@@ -557,8 +557,22 @@ class Catalog(CatalogBase):
# erg/s/cm2/A --> photon/s/m2/A
all_sed
=
y
*
lamb
/
(
cons
.
h
.
value
*
cons
.
c
.
value
)
*
1e-13
sed
=
Table
(
np
.
array
([
lamb
,
all_sed
]).
T
,
names
=
(
'WAVELENGTH'
,
'FLUX'
))
if
obj
.
type
==
'quasar'
:
# integrate to get the magnitudes
# if obj.type == 'quasar':
# # integrate to get the magnitudes
# sed_photon = np.array([sed['WAVELENGTH'], sed['FLUX']]).T
# sed_photon = galsim.LookupTable(x=np.array(sed_photon[:, 0]), f=np.array(
# sed_photon[:, 1]), interpolant='nearest')
# sed_photon = galsim.SED(
# sed_photon, wave_type='A', flux_type='1', fast=False)
# interFlux = integrate_sed_bandpass(
# sed=sed_photon, bandpass=self.filt.bandpass_full)
# obj.param['mag_use_normal'] = getABMAG(
# interFlux, self.filt.bandpass_full)
# # mag = getABMAG(interFlux, self.filt.bandpass_full)
# # print("mag diff = %.3f"%(mag - obj.param['mag_use_normal']))
# integrate to get the magnitudes
if
obj
.
type
==
'quasar'
or
obj
.
type
==
'galaxy'
:
sed_photon
=
np
.
array
([
sed
[
'WAVELENGTH'
],
sed
[
'FLUX'
]]).
T
sed_photon
=
galsim
.
LookupTable
(
x
=
np
.
array
(
sed_photon
[:,
0
]),
f
=
np
.
array
(
sed_photon
[:,
1
]),
interpolant
=
'nearest'
)
...
...
This diff is collapsed.
Click to expand it.
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
Menu
Explore
Projects
Groups
Snippets