Skip to main content

The survey simulator post processing code for the LSST

Project description


An open-source community LSST Solar System Simulator

ci pytest Documentation Status

LSST stack based post-processing modules in python for the JPL survey simulator: https://github.com/AsteroidSurveySimulator/objectsInField

Currently tested with the following fork: https://github.com/eggls6/objectsInField

Other software utilities can be found in this github repository: https://github.com/dirac-institute/sorcha_communiity_utils/

Documentation: https://sorcha.readthedocs.io

developer best practices

  • Data sets should be moved to the data folder, have a readme.txt or readme.md to explain where the data came from as well as a time stamp in the readme.txt.
  • Data sets that are used for unit testing should live in data/test.
  • All required input files for the main software or unit tests should have extensions that clearly describe the file format (e.g. .csv, .txt, .db, .fits)
  • Function/methods names should follow Rubin / LSST developer guide conventions: https://developer.lsst.io/
  • If you are working on addressing a specific issue ticket, assign yourself the ticket and set the status to "in progress"
  • When making a pull request that closes an issue, cite the issue ticket in the pull request summary

Making pip work

When making edits to the code, its likely that the only thing you need to worry about is making sure the imports are consistent. There are two places where this is important, the sorcha/sorcha.py file and the sorcha/modules/init.py file. If you want to add, remove or change the name of a module, then these files need to be updated to reflect that.

Within the sorcha/modules/init.py file it will look something like this:

from . import PPAddUncertainties

And in the sorcha.py file it will look something like this:

from sorcha.modules import PPAddUncertainties

When adding, removing or changing the name of any module, just make sure that you've updated both of these files to reflect the changes.

If you want to make some more major changes, e.g. adding another utility to the command line, then there are two things to keep in mind. Firstly, the python file containing the utility has to be formatted in a specific way and secondly, the setup.py file has to be changed.

Examples of the file formatting can be seen in sorcha.py, makeConfigOIF and makeConfigPP, so you can try to follow that. In short, you need to define the main containing the parser arguments, e.g.

def main():
    parser=argparse.ArgumentParser(description='creating config file(s) for Objects in Field')
    parser.add_argument("o", help="orbits file", type=str)
    etc....

and then after, include:

if __name__=='__main__':
    main()

pyproject.toml is the file which contains the information for the install. This contains some general information on things contact information for the author. Generally this file won't have to be changed unless you want to:

  • Update the author info etc. : this can just be manually changed.

  • Add a prerequisite package e.g. pandas: this can be added in the dependencies section just by adding the name of the prerequisite package to the list. This means that the package will be installed alongside sorcha. Specific versions can be added e.g. 'pandas==1.3.5'

  • Add a new command line argument: In the case of adding new utilities (e.g. the config file generators). This is a bit more complicated and relies on the file being in the format given above. If this is the case then a new function can be added to the entry_points

 [project.scripts]
        makeConfigSorcha = "sorcha.utilities.makeConfigPP:main"
    },

where makeConfigSorcha is the name of the command line argument, and sorcha.utilities.makeConfigPP:main is the file path.

Collaboration

This effort is a collaboration between Queen's University Belfast, the University of Washington's DiRAC Institute, the University of Illinois at Urbana-Champaign, the Center for Astrophysics | Harvard & Smithsonian, and LINCC Frameworks (through the LINCC Frameworks Incubator Program).

LINCC Frameworks is supported by Schmidt Futures, a philanthropic initiative founded by Eric and Wendy Schmidt, as part of the Virtual Institute of Astrophysics (VIA).

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

sorcha-0.3.tar.gz (40.1 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sorcha-0.3-py3-none-any.whl (123.5 kB view details)

Uploaded Python 3

File details

Details for the file sorcha-0.3.tar.gz.

File metadata

  • Download URL: sorcha-0.3.tar.gz
  • Upload date:
  • Size: 40.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for sorcha-0.3.tar.gz
Algorithm Hash digest
SHA256 bba05820721043cdb998d7463f9016c594012e89291619415dd699d7de533f01
MD5 7932e5ff06cf807d1b522a96cad99535
BLAKE2b-256 5a267ff05a00577c2797d4ed7525226b0ffd040a0d73af2d1260c6968c02b9f1

See more details on using hashes here.

File details

Details for the file sorcha-0.3-py3-none-any.whl.

File metadata

  • Download URL: sorcha-0.3-py3-none-any.whl
  • Upload date:
  • Size: 123.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/4.0.2 CPython/3.11.4

File hashes

Hashes for sorcha-0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 47d7ae97936d07727fef8720d9a5b6bd311b80c1fac669eb13f4e072ffb1a882
MD5 ae686d03936ce8514003ad199dbcb9fb
BLAKE2b-256 01640f2cd55586f3828eda307736edd01483562e9c3beeed22fdd07e27d0b821

See more details on using hashes here.

Supported by

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