output path renamed

This commit is contained in:
Lukas Klass 2020-05-23 16:25:00 +02:00
parent 1c255dcdcc
commit 4aa35f53c0
2 changed files with 9 additions and 5 deletions

View File

@ -9,9 +9,11 @@
<psf val="Airy" osf="10" osf_unit="" comment="PSF of the optical system. Can be Airy or a file"/>
<!-- <psf val="data/psf_2um.txt" osf="10" osf_unit="" comment="PSF of the optical system. Can be Airy or a file"/>-->
<!-- <jitter_sigma val="10" val_unit="arcsec" comment="Sigma of the telescope jitter"/>-->
<output_path val="output" comment="Output directory to store output files"/>
<exposure_time val="0.01" val_unit="s" comment="The exposure time"/>
<snr val="10" val_unit="" comment="Desired signal to noise ratio"/>
<output path="output" format="fits" comment="Output directory to store output files"/>
<exposure_time val="0.1, 1.2" val_unit="s" comment="The exposure time"/>
<!-- <snr val="10, 10, 10" val_unit="" comment="Desired signal to noise ratio"/>-->
<!-- <snr val="data/snr.csv" comment="Desired signal to noise ratio"/>-->
<!-- <snr val="10" val_unit="" comment="Desired signal to noise ratio"/>-->
</common>
<astroscene>

View File

@ -138,8 +138,10 @@ class Configuration(object):
mes = self.conf.common.jitter_sigma.check_quantity("val", u.arcsec)
mes is not None and error("Configuration check: common -> jitter_sigma: " + mes)
if hasattr(self.conf.common, "output_path"):
mes = self.conf.common.output_path.check_path("val")
mes is not None and error("Configuration check: common -> output_path: " + mes)
mes = self.conf.common.output.check_path("path")
mes is not None and error("Configuration check: common -> output: " + mes)
mes = self.conf.common.output.check_selection("format", ["csv", "CSV", "fits", "FITS"])
mes is not None and error("Configuration check: common -> output: " + mes)
else:
setattr(self.conf.common, "output_path", Entry(val="."))
if hasattr(self.conf.common, "exposure_time"):