Sophie

Sophie

distrib > Mageia > 4 > x86_64 > by-pkgid > 79aa700fb313c8058f07224ec56386c7 > files > 913

munipack-2.0.8-2.mga4.x86_64.rpm



<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml">
  <head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    
    <title>Using command-line tools &mdash; C-Munipack 2.0.8 documentation</title>
    
    <link rel="stylesheet" href="_static/default.css" type="text/css" />
    <link rel="stylesheet" href="_static/pygments.css" type="text/css" />
    
    <script type="text/javascript">
      var DOCUMENTATION_OPTIONS = {
        URL_ROOT:    '',
        VERSION:     '2.0.8',
        COLLAPSE_INDEX: false,
        FILE_SUFFIX: '.html',
        HAS_SOURCE:  true
      };
    </script>
    <script type="text/javascript" src="_static/jquery.js"></script>
    <script type="text/javascript" src="_static/underscore.js"></script>
    <script type="text/javascript" src="_static/doctools.js"></script>
    <link rel="top" title="C-Munipack 2.0.8 documentation" href="index.html" />
    <link rel="up" title="Command line tools" href="command_line_tools.html" />
    <link rel="next" title="Program arguments" href="program_arguments.html" />
    <link rel="prev" title="Command line tools" href="command_line_tools.html" /> 
  </head>
  <body>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             accesskey="I">index</a></li>
        <li class="right" >
          <a href="program_arguments.html" title="Program arguments"
             accesskey="N">next</a> |</li>
        <li class="right" >
          <a href="command_line_tools.html" title="Command line tools"
             accesskey="P">previous</a> |</li>
        <li><a href="index.html">C-Munipack 2.0.8 documentation</a> &raquo;</li>
          <li><a href="command_line_tools.html" accesskey="U">Command line tools</a> &raquo;</li> 
      </ul>
    </div>  

    <div class="document">
      <div class="documentwrapper">
        <div class="bodywrapper">
          <div class="body">
            
  <span class="target" id="index-0"></span><div class="section" id="using-command-line-tools">
<h1>Using command-line tools<a class="headerlink" href="#using-command-line-tools" title="Permalink to this headline">ΒΆ</a></h1>
<p>The following text describes the basic procedure for processing an observation of a
short-periodic variable star by means of the C-Munipack toolkit.</p>
<p>The package with demo data used here is available on the project&#8217;s web pages. Unzip
the archive to an empty folder at your hard disk (e.g. ~/c-munipack/sample), open a shell
or command-line window and make the folder your current working directory. The archive
has got the following structure:</p>
<table border="1" class="docutils">
<colgroup>
<col width="45%" />
<col width="55%" />
</colgroup>
<tbody valign="top">
<tr class="row-odd"><td><tt class="file docutils literal"><span class="pre">dark</span> <span class="pre">/</span> <span class="pre">20s</span> <span class="pre">/</span> <span class="pre">masterdark.fts</span></tt></td>
<td>master-dark frame (20 seconds exposure)</td>
</tr>
<tr class="row-even"><td><tt class="file docutils literal"><span class="pre">dark</span> <span class="pre">/</span> <span class="pre">20s</span> <span class="pre">/</span> <span class="pre">raw</span> <span class="pre">/</span> <span class="pre">dark*.fts</span></tt></td>
<td>set of raw dark frames (20 seconds exposure)</td>
</tr>
<tr class="row-odd"><td><tt class="file docutils literal"><span class="pre">flat</span> <span class="pre">/</span> <span class="pre">v</span> <span class="pre">/</span> <span class="pre">masterflat.fts</span></tt></td>
<td>master-flat frame (optical filter V)</td>
</tr>
<tr class="row-even"><td><tt class="file docutils literal"><span class="pre">flat</span> <span class="pre">/</span> <span class="pre">raw</span> <span class="pre">/</span> <span class="pre">flat-v*.fts</span></tt></td>
<td>set of raw flat frames (optical filter V)</td>
</tr>
<tr class="row-odd"><td><tt class="file docutils literal"><span class="pre">data</span> <span class="pre">/</span> <span class="pre">v</span> <span class="pre">/</span> <span class="pre">frame*.fts</span></tt></td>
<td>sample CCD frames (optical filter V)</td>
</tr>
</tbody>
</table>
<p>The reduction of CCD data has the following general scheme:</p>
<ol class="arabic simple">
<li>Conversion of input files to a working format</li>
<li>Calibration</li>
<li>Photometry and matching</li>
<li>Making output</li>
</ol>
<p>Most of widely used CCD camera controlling software save the data in FITS format,
which has virtually became the standard in this field. This is also a working format
for all tools from the C-Munipack project - it means, that they expect the FITS files
on their input and saves the output in this format, too. There is one exception to this
rule, the <strong class="command">konve</strong> command, which reads several different formats and
convert them to FITS. See the documentation for the <strong class="command">konve</strong> command
for the list of supported formats. If your files are not in FITS format, use this
command to convert your source files to the FITS format.</p>
<div class="highlight-python"><pre>mkdir tmp
konve -o tmp/frame???.fts your-files/\*.st7</pre>
</div>
<p>Even if your input files are saved in the FITS format, I would suggest you to
make a local copy, because it&#8217;s always advisory to play safe and make sure you don&#8217;t
tamper your original data with a misprint in a command. You can use the <strong class="command">konve</strong>
command or just simple <strong class="command">cp</strong> command for this job, but I will use the former
to demonstrate its use.</p>
<div class="highlight-python"><pre>mkdir tmp
konve -o tmp/frame???.fts data/v/\*.fts</pre>
</div>
<p>First command makes a new folder, that we will use for storing all temporary files hereafter.
The second line makes a copy of all sample frames to it.</p>
<p>A raw CCD frame consists of several components. By the calibration process, we get rid of those
which affect the result of the photometry. In some literature, the calibration is depicted as the
peeling of an onion. There are three major components which a raw frame consists of - the current
made by incident light, current made thermal drift of electrons (so-called dark current) and
constant bias level. In standard calibration scheme, which we will demonstrate here, the dark-frame
correction subtracts the dark current and the also the bias. Because of the nature of the dark current,
it is necessary to use a correction frame of the same exposure duration as source files and it must
be carried out on the same CCD temperature, too. Thus, the properly working temperature regulation
on your CCD camera is vital. The dark-frame calibration is made by means of the <strong class="command">darkbat</strong>
command.</p>
<div class="highlight-python"><pre>darkbat -o tmp/dark???.fts dark/20s/masterdark.fts tmp/frame*.fts</pre>
</div>
<p>Then, we have to compensate the spatial non-uniformity of a detector and whole optical
system. These non-uniformities are due to the fabrication process of a CCD chip and they are
also natural properties of all real optical components, lenses in particular. The flat-frame
correction uses a flat-frame to smooth them away. The flat-frame is a frame carried out
while the telescope is pointed to uniformly luminous area. In practice, this condition is
very difficult to achieve, the clear sky before dusk is usually used instead. The <strong class="command">flatbat</strong>
has very similar syntax to the previous one.</p>
<div class="highlight-python"><pre>flatbat -o tmp/flat???.fts flat/v/masterflat.fts tmp/dark*.fts</pre>
</div>
<p>The source files are calibrated now. We are ready to detect a stars on each frames and measure
their brightness. This process is called the photometry and unlike the previous commands, the result
is saved to a XML based file, so-called photometry file. There are a lot of parameters which affect
the star detection and also the brightness computation. In this example, the default values work fine,
but I would suggest you to become familiar with at least two of them - FWHM and Threshold - before
you start a real work.</p>
<div class="highlight-python"><pre>muniphot -o tmp/frame???.pht tmp/flat*.fts</pre>
</div>
<p>The previous command treated all source files independently. As a result of this, a star #1
in one file is not necessarily the same as a star #1 in another file. The process called matching
finds correspondences between them and a unique identifier is assigned to each star. Before we do
so, we have to choose one frame, which shall be used as a reference frame. In my experience, the
frame with the greatest number of stars works the best. For our example, let&#8217;s pick up the third
frame - <tt class="file docutils literal"><span class="pre">frame003.pht</span></tt>.</p>
<div class="highlight-python"><pre>munimatch -o tmp/match???.pht tmp/frame003.pht tmp/frame*.pht</pre>
</div>
<p>The sample data is the observation of an eclipsing binary star. For most of such observers,
the goal is to make a light curve. A light curve is a table, which consists of at least two
columns - time stamp expressed as a Julian date and difference between two stars - a variable star
and a comparison star. A variable star is a star that is subject of brightness variation and
a comparison star is supposed to be constant. Before we go on, we have to find out the identifiers
of at the variable star and the comparison star. This task is very difficult to perform on a
command-line, so I will skip it for the present. If you followed the previous step, the variable
star is #1 and the comparison is #2.</p>
<p>Now, we have got all information we need to make a light curve. This is done by means of
the <strong class="command">munilist</strong> command.</p>
<div class="highlight-python"><pre>munilist -v 1 -c 2 output.txt tmp/match*.pht</pre>
</div>
<p>Let&#8217;s have a look on the output file. The first several line should look like this:</p>
<div class="highlight-python"><pre>JD V-C s1
ApertureIndex = 1
ApertureRadius = 2.0000
Filter =  V

2453614.46632 -0.1058 0.0110
2453614.47054 -0.0952 0.0108
...</pre>
</div>
<p>The first line is a table header. It consists of names of table columns separated by a space.
The following lines up to the single empty line form the file header. They provide the
descriptive information about the data stored in the file. Each line consists of a keyword,
the equal sign an the value. After an empty line, the table data follows. Each row is written
on a separate line and columns are divided by a space.</p>
</div>


          </div>
        </div>
      </div>
      <div class="sphinxsidebar">
        <div class="sphinxsidebarwrapper">
  <h4>Previous topic</h4>
  <p class="topless"><a href="command_line_tools.html"
                        title="previous chapter">Command line tools</a></p>
  <h4>Next topic</h4>
  <p class="topless"><a href="program_arguments.html"
                        title="next chapter">Program arguments</a></p>
<div id="searchbox" style="display: none">
  <h3>Quick search</h3>
    <form class="search" action="search.html" method="get">
      <input type="text" name="q" />
      <input type="submit" value="Go" />
      <input type="hidden" name="check_keywords" value="yes" />
      <input type="hidden" name="area" value="default" />
    </form>
    <p class="searchtip" style="font-size: 90%">
    Enter search terms or a module, class or function name.
    </p>
</div>
<script type="text/javascript">$('#searchbox').show(0);</script>
        </div>
      </div>
      <div class="clearer"></div>
    </div>
    <div class="related">
      <h3>Navigation</h3>
      <ul>
        <li class="right" style="margin-right: 10px">
          <a href="genindex.html" title="General Index"
             >index</a></li>
        <li class="right" >
          <a href="program_arguments.html" title="Program arguments"
             >next</a> |</li>
        <li class="right" >
          <a href="command_line_tools.html" title="Command line tools"
             >previous</a> |</li>
        <li><a href="index.html">C-Munipack 2.0.8 documentation</a> &raquo;</li>
          <li><a href="command_line_tools.html" >Command line tools</a> &raquo;</li> 
      </ul>
    </div>
    <div class="footer">
        &copy; Copyright 2012, David Motl.
      Created using <a href="http://sphinx.pocoo.org/">Sphinx</a> 1.1.3.
    </div>
  </body>
</html>