Commit 2f9d9be7 authored by Yannick Roehlly's avatar Yannick Roehlly

Merge branch 'release/v0.5.1'

parents 4851956f 4484d1f8
# SCUBA450
#photon
# SCUBA 450um
375000.00 1.0E-4
380035.47 2.0E-4
390015.60 4.0E-4
400000.00 0.0012
410004.10 0.0046
420050.41 0.0178
430045.87 0.1134
435034.80 0.2508
440011.73 0.3843
445037.83 0.4042
450045.00 0.3963
455028.06 0.3803
460052.14 0.2996
465044.18 0.1942
470072.08 0.1072
475059.38 0.0482
480000.00 0.0212
485044.46 0.0117
490035.94 0.0105
500000.00 0.0074
510030.60 0.0047
520020.80 0.0029
540054.00 9.0E-4
560014.93 3.0E-4
580046.40 2.0E-4
600000.00 1.0E-4
3750000.0 1.0E-4
3800354.7 2.0E-4
3900156.0 4.0E-4
4000000.0 0.0012
4100041.0 0.0046
4200504.1 0.0178
4300458.7 0.1134
4350348.0 0.2508
4400117.3 0.3843
4450378.3 0.4042
4500450.0 0.3963
4550280.6 0.3803
4600521.4 0.2996
4650441.8 0.1942
4700720.8 0.1072
4750593.8 0.0482
4800000.0 0.0212
4850444.6 0.0117
4900359.4 0.0105
5000000.0 0.0074
5100306.0 0.0047
5200208.0 0.0029
5400540.0 9.0E-4
5600149.3 3.0E-4
5800464.0 2.0E-4
6000000.0 1.0E-4
......@@ -60,7 +60,7 @@ class PdfAnalysis(AnalysisModule):
"array of strings",
"List of the variables (in the SEDs info dictionaries) for which "
"the statistical analysis will be done.",
["sfr", "average_sfr"]
["sfr", "sfr10Myrs", "sfr100Myrs"]
)),
("save_best_sed", (
"boolean",
......
......@@ -338,7 +338,7 @@ def analysis(idx, obs):
# We check how many unique parameter values are analysed and if less
# than Npdf (= 100), the PDF is initally built assuming a number of
# bins equal to the number of unique values for a given parameter
# (e.g., average_sfr, age, attenuation.uv_bump_amplitude,
# (e.g., sfr, age, attenuation.uv_bump_amplitude,
# dust.luminosity, attenuation.FUV, etc.).
Npdf = 100
var = np.empty((Npdf, len(analysed_averages)))
......
......@@ -48,12 +48,13 @@ class SaveFluxes(AnalysisModule):
parameter_list = OrderedDict([
("output_file", (
"string",
"Name of the output file.",
"Name of the output file that contains the parameters of the model(s) "
"and the flux densities in the bands",
"computed_fluxes.txt"
)),
("save_sed", (
"boolean",
"If True, save the generated SED.",
"If True, save the generated spectrum for each model.",
"False"
)),
("output_format", (
......
......@@ -50,8 +50,10 @@ class BC03(CreationModule):
out_parameter_list = OrderedDict([
("sfr", "Instantaneous Star Formation Rate in solar mass per year, "
"at the age of the galaxy."),
("average_sfr", "Average SFR in the last 100 Myr (default) of the "
"galaxy history."),
('sfr10Myrs', 'Average SFR in the last 10 Myr (default) of the '
'galaxy history.'),
('sfr100Myrs', 'Average SFR in the last 100 Myr (default) of the '
'galaxy history.'),
("ssp_m_star", "Total mass in stars in Solar mass."),
("ssp_m_gas", "Mass returned to the ISM by evolved stars in Solar "
"mass."),
......
......@@ -31,8 +31,9 @@ class Dale2014(CreationModule):
parameter_list = OrderedDict([
('fracAGN', (
'float',
"AGN fraction.",
0.1
"AGN fraction "
"[it is not recommended to combine this AGN emission with that of Fritz et al. (2006)]",
0.0
)),
('alpha', (
'float',
......
......@@ -62,7 +62,9 @@ class M2005(CreationModule):
out_parameter_list = OrderedDict([
('sfr', 'Instantaneous Star Formation Rate in solar mass per year, '
'at the age of the galaxy.'),
('average_sfr', 'Average SFR in the last 100 Myr (default) of the '
('sfr10Myrs', 'Average SFR in the last 10 Myr (default) of the '
'galaxy history.'),
('sfr100Myrs', 'Average SFR in the last 100 Myr (default) of the '
'galaxy history.'),
('mass_total', 'Total stellar mass of the galaxy in solar mass.'),
('mass_alive', 'Mass of alive stars in solar mass.'),
......
......@@ -85,7 +85,9 @@ class SED(object):
sfh_age = sfh_time[-1] - sfh_time
self._sfh = value
self.add_info("sfr", sfh_sfr[-1], True, True)
self.add_info("average_sfr", np.mean(sfh_sfr[-AV_LAPSE:]),
self.add_info("sfr10Myrs", np.mean(sfh_sfr[-10:]),
True, True)
self.add_info("sfr100Myrs", np.mean(sfh_sfr[-100:]),
True, True)
self.add_info("age", sfh_time[-1], False, True)
......
......@@ -188,11 +188,11 @@ def _sed_worker(obs, mod, filters, sed_type, nologo):
label="Dust emission", color='r', marker=None,
nonposy='clip', linestyle='-', linewidth=0.5)
# AGN emission Fritz
if 'agn_fritz2006_therm' in sed.columns:
if 'agn.fritz2006_therm' in sed.columns:
ax1.loglog(wavelength_spec[wsed],
(sed['agn_fritz2006_therm'][wsed] +
sed['agn_fritz2006_scatt'][wsed] +
sed['agn_fritz2006_agn'][wsed]),
(sed['agn.fritz2006_therm'][wsed] +
sed['agn.fritz2006_scatt'][wsed] +
sed['agn.fritz2006_agn'][wsed]),
label="AGN emission", color='g', marker=None,
nonposy='clip', linestyle='-', linewidth=0.5)
# Radio emission
......
......@@ -3,9 +3,10 @@
# Licensed under the CeCILL-v2 licence - see Licence_CeCILL_V2-en.txt
# Author: Yannick Roehlly
from setuptools import setup, find_packages
from distutils.command.build import build
from setuptools import find_packages, setup
class custom_build(build):
def run(self):
......@@ -17,12 +18,13 @@ class custom_build(build):
build.run(self)
entry_points = {
'console_scripts': ['pcigale = pcigale:main', 'pcigale-plots = pcigale_plots:main']
'console_scripts': ['pcigale = pcigale:main',
'pcigale-plots = pcigale_plots:main']
}
setup(
name="pcigale",
version="0.1a",
version="0.5.1",
packages=find_packages(exclude=["database_builder"]),
install_requires=['numpy', 'scipy', 'sqlalchemy', 'matplotlib',
......@@ -30,14 +32,13 @@ setup(
entry_points=entry_points,
include_package_data=True,
cmdclass={"build": custom_build},
package_data={'pcigale': ['data/data.db'], 'pcigale-plots':['data/CIGALE.png']},
package_data={'pcigale': ['data/data.db'],
'pcigale_plots': ['data/CIGALE.png']},
author="Yannick Roehlly",
author_email="yannick.roehlly@oamp.fr",
author="The CIGALE team",
author_email="cigale@lam.fr",
description="Python Code Investigating Galaxy Emission",
license="CeCILL-V2",
keywords="astrophysics, galaxy, SED fitting"
)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment