Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
cigale
CIGALE
Commits
4d209ab0
Commit
4d209ab0
authored
May 14, 2014
by
Médéric Boquien
Browse files
Extend the quasar spectrum down to shorter wavelength. Update from Daniel Dale.
parent
3dbd0d67
Changes
4
Expand all
Hide whitespace changes
Inline
Side-by-side
database_builder/__init__.py
View file @
4d209ab0
...
...
@@ -369,22 +369,16 @@ def build_dale2014(base):
base
.
add_dale2014
(
Dale2014
(
fraction
,
alpha_grid
[
al
-
1
],
wave
,
lumin
))
# Emission from dust heated by AGN - Quasar template
fraction
=
1.0
filename
=
dale2014_dir
+
"spectra.1.00AGN.dat"
filename
=
dale2014_dir
+
"shi_agn.regridded.extended.dat"
print
(
"Importing {}..."
.
format
(
filename
))
datafile
=
open
(
filename
)
data
=
""
.
join
(
datafile
.
readlines
())
datafile
.
close
()
for
al
in
range
(
1
,
len
(
alpha_grid
),
1
):
lumin_quasar
=
np
.
genfromtxt
(
io
.
BytesIO
(
data
.
encode
()),
usecols
=
(
al
))
lumin_quasar
=
pow
(
10
,
lumin_quasar
)
/
wave
lumin_quasar
[
lumin_quasar
<
0
]
=
0
norm
=
np
.
trapz
(
lumin_quasar
,
x
=
wave
)
lumin_quasar
=
lumin_quasar
/
norm
base
.
add_dale2014
(
Dale2014
(
fraction
,
alpha_grid
[
al
-
1
],
wave
,
lumin_quasar
))
wave
,
lumin_quasar
=
np
.
genfromtxt
(
filename
,
unpack
=
True
)
wave
*=
1e3
lumin_quasar
=
10
**
lumin_quasar
/
wave
norm
=
np
.
trapz
(
lumin_quasar
,
x
=
wave
)
lumin_quasar
=
lumin_quasar
/
norm
base
.
add_dale2014
(
Dale2014
(
1.0
,
0.0
,
wave
,
lumin_quasar
))
def
build_dl2007
(
base
):
...
...
database_builder/dale2014/shi_agn.regridded.extended.dat
0 → 100644
View file @
4d209ab0
This diff is collapsed.
Click to expand it.
database_builder/dale2014/spectra.1.00AGN.dat
deleted
100644 → 0
View file @
3dbd0d67
This diff is collapsed.
Click to expand it.
pcigale/creation_modules/dale2014.py
View file @
4d209ab0
...
...
@@ -60,7 +60,7 @@ class Dale2014(CreationModule):
with
Database
()
as
database
:
self
.
model_sb
=
database
.
get_dale2014
(
0.00
,
alpha
)
self
.
model_quasar
=
database
.
get_dale2014
(
1.00
,
alpha
)
self
.
model_quasar
=
database
.
get_dale2014
(
1.00
,
0.0
)
def
process
(
self
,
sed
):
"""Add the IR re-emission contributions
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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