Commit 683de3cf authored by karpov-sv's avatar karpov-sv
Browse files

Minor documentation fixes

parent 4c813d9b
......@@ -9,7 +9,8 @@ Design principles:
- implemented as a library of routines covering most common tasks
- operates on standard Python objects: NumPy arrays for images, Astropy Tables for catalogs and object lists, etc
- does not try to re-implement the things already implemented in other Python packages
- conveniently wraps external codes that do not have their own Python interfaces (*SExtractor*, *SCAMP*, *PSFEx*, *HOTPANTS*, *Astrometry.Net*, ...)
- conveniently wraps external codes that do not have their own Python interfaces (*SExtractor*, *SCAMP*, *PSFEx*, *HOTPANTS*, *Astrometry.Net*, ...):
- wrapping is transparent: all data passed from Python, all options customizable from Python, all (or most of) outputs available back
- everything operates on temporary files, nothing is kept after the run unless explicitly asked for
......
......@@ -85,6 +85,9 @@ Use the commands below to install the rest of dependencies and the package itsel
* $ python setup.py develop
Alternative installation command (try it if the one above fails - they use slightly different strategies of installing the dependencies, so results may really vary!) would be
* $ pip install -e .
**Keeping up to date**
......
......@@ -38,7 +38,7 @@ Data processing
---------------
.. toctree::
:maxdepth: 2
:maxdepth: 3
preprocessing
detection
......@@ -52,9 +52,21 @@ Data processing
Common principles
-----------------
The functions included in *STDPipe* try to follow several common principles related to their behaviour and arguments. They are summarized below.
The functions included in *STDPipe* try to follow several common conventions related to their behaviour and arguments. They are summarized below.
- Most of functions accept `verbose` argument that controls the amount of informational outputs the function produces. You may use `verbose=True` to see the details of what exactly the function is doing. Also, you may pass any `print`-like function to this argument to receive the messages instead of printing - so e.g. they may be logged.
Design principles:
- The routines operate on standard Python objects: NumPy arrays for images, Astropy Tables for catalogs and object lists, etc
- Some of them conveniently wrap external codes (*SExtractor*, *SCAMP*, *PSFEx*, *HOTPANTS*, *Astrometry.Net*, ...):
- all data are passed from Python, all options are customizable from Python, all (or most of) outputs available back.
- no configuration files are necessary or being used by default, but you may of course let the underlying executable to use a config file by passing corresponding options to it
- everything operates on temporary files, nothing is kept after the run unless explicitly asked for
- temporary files are created in unique temporary directories for each run, so several instances of routines may be safely run in parallel
Common conventions for routine arguments:
- Most of functions accept `verbose` argument that controls the amount of informational outputs the function produces. You may use `verbose=True` to see the details of what exactly the function is doing. Also, you may pass any `print`-like function to this argument to receive the messages instead of printing - so e.g. they may be logged.
.. code-block:: python
......@@ -75,8 +87,8 @@ The functions included in *STDPipe* try to follow several common principles rela
# Now use it to redirect STDPipe function output to log file
obj = photometry.get_objects_sextractor(image, mask=mask, verbose=verbose)
- Functions that produce (and then delete of course) some temporary files during its operation usually accept `_tmpdir` argument to manually specify the location where these temporary files (usually in a dedicated per-task temporary folder, so thread-safe and stuff) will be stored. This is useful if your system-wide temporary directory (usually :file:`/tmp` in Linux) is low on free space - then you may use some larger volume for storing temporary files by adding `_tmpdir=/large/volume/tmp` to function call.
- Functions that produce (and then delete of course) some temporary files during its operation usually accept `_tmpdir` argument to manually specify the location where these temporary files (usually in a dedicated per-task temporary folder, so thread-safe and stuff) will be stored. This is useful if your system-wide temporary directory (usually :file:`/tmp` in Linux) is low on free space - then you may use some larger volume for storing temporary files by adding `_tmpdir=/large/volume/tmp` to function call.
- Functions that operate on temporary files in temporary folders may be supplied with `_workdir` argument - then they will store all temporary files related to their work in this specific folder, and will not remove them afterwards. So e.g. you will be able to directly see e.g what configuration files were created, manually re-run the failed command to experiment with its options (with `verbose=True` function call typically prints the complete command line of all calls to external programs, so you may just directly copy and paste it to terminal to repeat its invocation), etc.
- Functions that operate on temporary files in temporary folders may be supplied with `_workdir` argument - then they will store all temporary files related to their work in this specific folder, and will not remove them afterwards. So e.g. you will be able to directly see e.g what configuration files were created, manually re-run the failed command to experiment with its options (with `verbose=True` function call typically prints the complete command line of all calls to external programs, so you may just directly copy and paste it to terminal to repeat its invocation), etc.
- Functions that run external programs (e.g. SExtractor, HOTPANTS, or Astrometry.Net) usually accept `_exe` argument to directly specify the path to corresponding executable. If not specified, the code will try to automatically find it for you, so normally you do not need to worry about it.
- Functions that run external programs (e.g. SExtractor, HOTPANTS, or Astrometry.Net) usually accept `_exe` argument to directly specify the path to corresponding executable. If not specified, the code will try to automatically find it for you, so normally you do not need to worry about it.
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