Config.rst 1.88 KB
Newer Older
1
2
.. File Config.rst

Emmanuel Bertin's avatar
Emmanuel Bertin committed
3
4
.. include:: global.rst

5
6
.. _config_file:

7
The configuration file
8
----------------------
9

Emmanuel Bertin's avatar
Emmanuel Bertin committed
10
11
12
Each time it is run, |SExtractor| looks for a configuration file.
If no configuration file is specified in the command-line, it is assumed to be called :file:`default.sex` and to reside in the current directory.
If no configuration file is found, |SExtractor| will use its own internal default configuration.
13
14

Creating a configuration file
15
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
16

Emmanuel Bertin's avatar
Emmanuel Bertin committed
17
18
SExtractor can generate an ASCII dump of its internal default configuration, using the ``-d`` option.
By redirecting the standard output of SExtractor to a file, one creates a configuration file that can easily be modified afterwards:
19
20
21
22
23

.. code-block:: console

  $ sex -d > default.sex

Emmanuel Bertin's avatar
Emmanuel Bertin committed
24
A more extensive dump with less commonly used parameters can be generated by using the ``-dd`` option.
25
26

Format of the configuration file
27
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
28

Emmanuel Bertin's avatar
Emmanuel Bertin committed
29
The format is ASCII. There must be only one parameter set per line, following the form::
30
31
32

 Config-parameter      Value(s)

Emmanuel Bertin's avatar
Emmanuel Bertin committed
33
34
35
36
37
38
39
Extra spaces or linefeeds are ignored.
Comments must begin with a ``#`` and end with a linefeed.
Values can be of different types: strings (can be enclosed between double quotes), floats, integers, keywords or Boolean (`Y`/`y` or `N`/`n`).
Some parameters accept zero or several values, which must then be separated by commas.
Integers can be given as decimals, in octal form (preceded by digit O), or in hexadecimal (preceded by `0x`).
The hexadecimal format is particularly convenient for writing multiplexed bit values such as binary masks.
Environment variables, written as ``$HOME`` or ``${HOME}`` are expanded.
40
41
42
43

.. _param_list:

Configuration parameter list
44
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
45

Emmanuel Bertin's avatar
Emmanuel Bertin committed
46
47
Here is a complete list of all the configuration parameters known to |SExtractor|.
Please refer to the next sections for a detailed description of their meaning.
48
49