Skip to main content

Command line tool to call LCO source extraction service

Project description

LCO Source Extraction Service CLI

sep-service-caller

Command line interface to LCO's source extraction service

The source extraction service documentation can be found here: https://github.com/LCOGT/sextractor-service

Installation

pip install sep-service-caller

Logging

Logging is to STDOUT, with the ability to set the log level via the --log-level argument.

Extraction results are posted to LCO's Elasticsearch instance, and by default set to populate the source-extraction index.

The source-extraction index can be viewed in Kibana.

Usage

To view the help text, simply use the -h flag:

sep-service -h

usage: sep-service [-h] {file,dates} ...

Perform source extraction via the LCO source extraction service

positional arguments:
  {file,dates}  sep-service sub-commands
    file        Specify a basename to perform source extraction on
    dates       Specify a site/camera/date range to perform source extractions
                on.

optional arguments:
  -h, --help    show this help message and exit

The sep-service-caller has two sub-commands in order to facilitate two distict workflows:

  • file: perform source extraction on a single file, specified by basename
  • dates: perform source extraction on any number of files, specified by site/camera start and end date

Both commands accept the same optional parameters, allowing source extraction parameters to be provided.

See LCO's Source Extraction Service Docs

Examples

Note: All examples include <archive-auth-token>, which should be replaced by an Archive API Token that has access to the images that you wish to perform source extraction on.

Solve by file

To view the help text for this subcommand, simply type sep-service file -h. This will show all of the optional arguments available to you. Only a subset are showcased here.

To perform source extraction on a single file, lsc1m005-fa15-20200214-0355-e91

sep-service file lsc1m005-fa15-20200214-0355-e91 <archive-auth-token>

Let's try without DEFAULT values! Note, that you must specify --sep-mode CUSTOM to override the sep service's default values

sep-service file lsc1m005-fa15-20200214-0355-e91 <archive-auth-token> --sep-mode CUSTOM --threshold 8.0

In this case, threshold will be set to 8.0, but all other tunable sep parameters will stay at their default

You can override as many values as you wish! Go crazy!

sep-service file lsc1m005-fa15-20200214-0355-e91 <archive-auth-token> --sep-mode CUSTOM --threshold 8.0 --min-area 2 --noise-model GLOBALRMS

Solve by site/camera/date-range

To view the help text for this subcommand, simply type sep-service dates -h. This will show all of the optional arguments available to you. Only a subset are showcased here.

To perform source extraction on all reduced science images (e91) from LSC/fa15 on DAY-OBS 20200214, 20200215, and 20200216:

sep-service dates lsc fa15 20200214 20200216 <archive-auth-token>

Let's try without DEFAULT values! Note, that you must specify --sep-mode CUSTOM to override the sep service's default values

sep-service dates lsc fa15 20200214 20200216 <archive-auth-token> --sep-mode CUSTOM --deblend-n-threshold 24

In this case, like before, the number of deblending thresholds will be set to 24 but all other tunable sep parameters will stay at their default values.

You can override as many values as you wish.

sep-service dates lsc fa15 20200214 20200216 <archive-auth-token> --sep-mode CUSTOM --threshold 8.0 --min-area 2 --noise-model GLOBALRMS

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sep-service-caller-0.1.0.tar.gz (5.3 kB view details)

Uploaded Source

File details

Details for the file sep-service-caller-0.1.0.tar.gz.

File metadata

  • Download URL: sep-service-caller-0.1.0.tar.gz
  • Upload date:
  • Size: 5.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.43.0 CPython/3.7.3

File hashes

Hashes for sep-service-caller-0.1.0.tar.gz
Algorithm Hash digest
SHA256 e1813109a502b84a34772264ab023942ada85b5678b4f10e236312e3ee658cf2
MD5 c792cb59801cff1752706bcab02cc1f0
BLAKE2b-256 1774e74066596e4be9a49aa471a74f814efcf69b734773cdf92d29e986e8e959

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page