config_unit_simulunit1.xml 15.3 KB
<?xml version = '1.0' encoding = 'UTF-8'?>

<!--
=============================================================================
This File describes all the parameters that characterize a unit.
=============================================================================
One parameter <param></param> is defined using the following attributes:
section, key, value, type, unit, access, comment, label, reference, timestamp 

* Mandatory
section : Category of the keyword
key : Key of the keyword
value : Useful value of the keyword (=default value when defining a HTML form)

* Optional
type : Python type to interpret the value
unit : Physical value to allow conversions
access : 0brwrwrw (rw for PI-Mount, rw for Maintenance, rw for Astronomers)
comment : Comment to be added as a popup in the web page
label : Text to describe the value
reference : Refere to the source of the value
timestamp : Date when the value has been last updated
default_value : Default value (useful for web forms)

* Optional to describe a HTML form <form>
label : HTML Text to describe the value in a web page (for forms)
element : HTML form element tag (input, select, etc.)
element_attribute : HTML form element attributes
options : HTML tag <option> contents in case of HTML element <select>

=============================================================================
-->

<unit alias="SimulUnit1">

  <!-- Some informations about this configuration -->
  <date_creation>2018-04-13 00:38:14</date_creation>
  <date_last_modification>2019-02-18 16:38:00</date_last_modification>
  <author_last_modification>Alain Klotz</author_last_modification>
  <param section="unit" key="description" value="Unit of simulation No 1"/>

  <!-- Select the unit as one mount and one or more channels -->
  <param section="assembly" key="alias" value="PyROSDatabase" comment="database"/>
  <param section="assembly" key="alias" value="VirtualMount" comment="mount"/>
  <param section="assembly" key="alias" value="VirtualCamera1" comment="channel"/>
  
  <!-- A database definition -->
  <database alias="PyROSDatabase">
    <param section="database" key="description" value="PyROS database"/>
    <!-- Select the type of database (DBMS) -->
    <param section="management" key="system" value="MySQL"/>
    <!-- Access autorizations -->
    <param section="access" key="host" value="127.0.0.1"/>
    <param section="access" key="port" value="3306"/>
    <param section="access" key="user" value="pyros"/>
    <param section="access" key="pswd" value="6cacc99693b5bca5a2b9e37dbba529116d" type="str" unit="crypted1"/>
    <!-- Database characteristics -->
    <param section="database" key="name" value="pyros"/>
  </database>

  <!-- A mount definition -->
  <mount alias="VirtualMount">
    <!-- General description -->
    <param section="mount" key="description" value="Losmandy"/>
    <param section="mount" key="home" value="IRAP" type="str" unit="" comment="Institut de Recherche en Astrophysique et Planetologie"/>
    <param section="mount" key="iau_num" value="n.d" type="str" unit="" comment="Not defined"/>
    <!-- Set period parameters -->
    <param section="period" key="periods" value="(1, 2018, 9, 1, 2019, 3, 1), (2, 2019, 3, 1, 2019, 9, 1)" type="int" unit=""/>
    <param section="period" key="sun_elev_night" value="-10" type="float" unit="deg"/>
    <param section="partner" key="partners" value="(1, 'PAA', 45, 'Partner_A'), (1, 'PAB', 22, 'Partner_B'), (1, 'PAC', 33, 'Partner_C')" type="int" unit=""/>
    <!-- Set device controller agent -->
    <param section="MountPointing" key="agent" value="TelescopeSimulator" comment="Value must be the alias of the controller agent"/>
    <!-- Set mount paramters for simulations and scheduler -->
    <param section="MountPointing" key="home" value="GPS 1.477083 E 43.81667 150" type="str" unit=""/>
    <param section="MountPointing" key="axe_type" value="hadec" type="str" unit=""/>
    <param section="MountPointing" key="ha_liminf" value="-90" type="float" unit="Angle"/>
    <param section="MountPointing" key="ha_limsup" value="90" type="float" unit="Angle"/>
    <param section="MountPointing" key="dec_liminf" value="-30" type="float" unit="Angle"/>
    <param section="MountPointing" key="dec_limsup" value="89.7" type="float" unit="Angle"/>
    <param section="MountPointing" key="ha_vel_profile" value="scurve" type="str" unit=""/>
    <param section="MountPointing" key="dec_vel_profile" value="scurve" type="str" unit=""/>
  </mount>
  
  <!-- A channel definition -->
  <channel alias="VirtualCamera1">
    <!-- General description -->
    <param section="channel" key="description" value="Takahshi + Atik"/>
    <!-- Set device controller agent -->
    <param section="DetectorSensor"  key="agent" value="CameraSimulator" comment="Value must be the alias of the controller agent"/>
    <param section="DetectorShutter" key="agent" value="CameraSimulator" comment="Value must be the alias of the controller agent"/>
    <param section="DetectorTimer"   key="agent" value="CameraSimulator" comment="Value must be the alias of the controller agent"/>
    <param section="FilterSelector"  key="agent" value="CameraSimulator" comment="Value must be the alias of the controller agent"/>
    <param section="DetectorFocus"   key="agent" value="TelescopeSimulator" comment="Value must be the alias of the controller agent"/>
    <!-- Camera properties for plans and for simulations -->
    <param section="DetectorSensor" key="description" value="Atik 460" type="str" unit=""/>
    <param section="DetectorSensor" key="serial_number" value="S/N67Y" type="str" unit=""/>
    <param section="DetectorSensor" key="sensor_type" value="CCD" type="str" unit=""/>
    <param section="DetectorSensor" key="efficiency" value="0.9" type="float" unit=""/>
    <param section="DetectorSensor" key="binnings" value="(1, 1), (2, 2), (3, 3), (4,4)" type="list" unit=""/>
    <param section="DetectorSensor" key="exptime_mini" value="0.1" type="float" unit="sec"/>
    <param section="DetectorSensor" key="exptime_maxi" value="1000" type="float" unit="sec"/>
    <param section="DetectorSensor" key="readouttime" value="10" type="float" unit="sec"/>
    <param section="DetectorSensor" key="nbcells1" value="4096" type="int" unit=""/>
    <param section="DetectorSensor" key="cellsize1" value="15" type="float" unit="mu"/>
    <param section="DetectorSensor" key="nbcells2" value="4096" type="int" unit=""/>
    <param section="DetectorSensor" key="cellsize2" value="15" type="float" unit="mu"/>
    <param section="DetectorSensor" key="readoutnoise" value="7.5" type="float" unit="electrons"/>
    <param section="DetectorSensor" key="gain" value="2.5" type="float" unit="electrons/adu"/>
    <param section="DetectorSensor" key="temperature" value="-50" type="float" unit="degC"/>
    <param section="DetectorSensor" key="thermic_signal" value="0.05" type="float" unit="electrons/s"/>
    <!-- Shutter properties for plans and for simulations -->
    <param section="DetectorShutter" key="mode" value="synchro, openned, closed" type="str" unit=""/>
    <param section="DetectorShutter" key="delayopening" value="60" type="int" unit="us"/>
    <param section="DetectorShutter" key="delayclosing" value="30" type="int" unit="us"/>
    <!-- Filter properties for plans and for simulations -->
    <param section="FilterSelector" key="symbols" value="B g r i gri" type="str" unit=""/>
    <param section="FilterSelector" key="efficiencies" value="0.75 0.85 0.85 0.85 0.85 0.85" type="float" unit=""/>
    <param section="FilterSelector" key="lambda_mins" value="0.37 0.40 0.55 0.70 0.40" type="float" unit="mu"/>
    <param section="FilterSelector" key="lambda_maxs" value="0.50 0.55  0.70 0.80 0.80" type="float" unit="mu"/>
    <param section="FilterSelector" key="positions" value="0 60 120 180 240" type="float" unit="deg"/>
    <!-- Optical design of the channel for simulations -->
    <param section="optic" key="description" value="Takahashi epsilon" type="str" unit=""/>
    <param section="optic" key="serial_number" value="875432" type="str" unit=""/>
    <param section="optic" key="aperdiam" value="0.16" type="float" unit="m"/>
    <param section="optic" key="focleneq" value="0.53" type="float" unit="m"/>
    <param section="optic" key="efficiency" value="0.68" type="float" unit=""/>
    <!-- Atmospheric conditions for simulations -->
    <param section="atmosphere" key="temperature" value="300" type="float" unit="Kelvin"/>
    <param section="atmosphere" key="pressure" value="101325" type="float" unit="Pascal"/>
    <param section="atmosphere" key="humidity" value="50" type="float" unit="percent"/>
    <param section="atmosphere" key="seeing" value="1" type="float" unit="arcsec"/>
    <param section="atmosphere" key="transparency" value="0.8" type="float" unit="0b110101"/>
    <!-- Define the horizon line for scheduler -->
    <param section="horizon" key="amer_list" value="(0, 10), (50, 15), (60,10)" type="tuple" unit="Angle"/>
    <!-- Plan description of this channel for the web form and observations -->
    <plan>
      <param section="form" key="shutter"   label="Shutter mode"      value="1" element_tag="select" element_attributes='required' options="param DetectorShutter mode"/>
      <param section="form" key="filter"    label="Filter"            value=""  element_tag="select" element_attributes='required' options="param FilterSelector symbols"/>
      <param section="form" key="binning"   label="Binning"           value=""  element_tag="select" element_attributes='required' options="param DetectorSensor binnings"/>
      <param section="form" key="exptime"   label="Exposure time (s)" value="1" element_tag="input"  element_attributes='type="number" step="any" min="0.1" max="100"'/>
      <param section="form" key="nb_images" label="Number images"     value="1" element_tag="input"  element_attributes='type="number" step="1" min="1" max="10000"'/>
      <param section="form" key="delay"     label="Delay start (s)"   value="0" element_tag="input"  element_attributes='type="number" step="any" min="0" max="100"'/>
    </plan>
  </channel>
  
  <!-- A computer definition -->
  <computer alias="Computer1">
    <param section="computer" key="description" value="PC titanium Alain"/>
    <!-- Paths -->
    <param section="path" key="data" value="c:/srv/work/pyros"/>
    <!-- Access -->
    <param section="local" key="hostname" value="titanium" comment="returned by import socket;print(socket.gethostname())"/>
    <param section="local" key="ip" value="192.168.0.1"/>
    <param section="global" key="hostname" value="titanium.irap.omp.eu"/>
    <param section="global" key="www_port" value="80"/>
    <!-- Agents to launch on this computer -->
    <param section="agent_to_launch" key="alias" value="AgentX"/>
    <param section="agent_to_launch" key="alias" value="Monitoring"/>
    <param section="agent_to_launch" key="alias" value="TelescopeSimulator"/>
    <param section="agent_to_launch" key="alias" value="CameraSimulator"/>
  </computer>
  
  <!-- A computer definition -->
  <computer alias="Computer2">
    <param section="computer" key="description" value="Mac Etienne"/>
    <!-- Paths -->
    <param section="path" key="data" value="/PROJECTS/GFT/SOFT/PYROS_SOFT/DATA"/>
    <!-- Access autorizations -->
    <param section="local" key="hostname" value="macp1219.local" comment="returned by import socket;print(socket.gethostname())"/>
    <param section="local" key="ip" value="192.168.0.1"/>
    <param section="global" key="hostname" value="etienne.irap.omp.eu"/>
    <param section="global" key="www_port" value="80"/>
    <!-- Agents to launch on this computer -->
    <param section="agent_to_launch" key="alias" value="AgentX"/>
    <param section="agent_to_launch" key="alias" value="Monitoring"/>
    <param section="agent_to_launch" key="alias" value="TelescopeSimulator"/>
    <param section="agent_to_launch" key="alias" value="CameraSimulator"/>
  </computer>
  
  <!-- A computer definition -->
  <computer alias="Computer3">
    <param section="computer" key="description" value="PC Patrick"/>
    <!-- Access autorizations -->
    <param section="local" key="hostname" value="patrick" comment="returned by import socket;print(socket.gethostname())"/>
    <param section="local" key="ip" value="192.168.0.1"/>
    <param section="global" key="hostname" value="etienne.irap.omp.eu"/>
    <param section="global" key="www_port" value="80"/>
    <!-- Agents to launch on this computer -->
    <param section="agent_to_launch" key="alias" value="AgentX"/>
    <param section="agent_to_launch" key="alias" value="Monitoring"/>
    <param section="agent_to_launch" key="alias" value="TelescopeSimulator"/>
    <param section="agent_to_launch" key="alias" value="CameraSimulator"/>
  </computer>
  
  <!-- An agent definition -->
  <agent alias="Superagent1">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="../pyros_simulunit1/src/superagent1"/>
    <param section="code" key="tail_filename" value="SuperAgent1.py"/>
  </agent>
  
  <!-- An agent definition -->
  <agent alias="AgentX">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="src/agentx"/>
    <param section="code" key="tail_filename" value="AgentX.py"/>
  </agent>

  <!-- An agent definition -->
  <agent alias="AgentY">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="../pyros_simulunit1/src/agenty"/>
    <param section="code" key="tail_filename" value="AgentY.py"/>
  </agent>
  
  <!-- An agent definition -->
  <agent alias="TelescopeSimulator">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="src/telescopesimulator"/>
    <param section="code" key="tail_filename" value="TelescopeSimulator.py"/>
  </agent>

  <!-- An agent definition -->
  <agent alias="CameraSimulator">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="src/camerasimulator"/>
    <param section="code" key="tail_filename" value="CameraSimulator.py"/>
  </agent>
  
  <!-- An agent definition -->
  <agent alias="Monitoring">
    <!--  -->
    <param section="general" key="startmode" value="RUN"/>
    <!-- Where is the code to launch ? Concatenation of path0_filename + path1_filename + tail_filename -->
    <param section="code" key="path0_filename" value="$PYROS"/>
    <param section="code" key="path1_filename" value="src/monitoring"/>
    <param section="code" key="tail_filename" value="start_agent_monitoring.py"/>
  </agent>
  
</unit>