Skip to main content

OPCSIM: simulating low-cost optical particle counters

Project description

PyPI version DOI

license run and build codecov Docker Pulls Docker Stars

opcsim

opcsim is a Python library for simulating low-cost Optical Particle Sensors (both Optical Particle Counters and Nephelometers) and their response to various aerosol distributions.

Citation

The paper for this library can be found on the AMT website here. It should be cited as:

Hagan, D.H. and Kroll, J.H.: Assessing the accuracy of low-cost optical particle sensors using a physics-based approach, Atmos. Meas. Tech., 13, 6343-6355, https://doi.org/10.5194/amt-13-6343-2020, 2020.

Documentation

Full online documentation can be found here.

The docs include a tutorial, an example gallery, and an API Reference.

In addition, documentation can be built locally for development purposes. To do so, please check out the complete details in the contributing to opcsim section of the documentation.

Docker

If you are familiar with Docker, there is a Docker image available to get up and running with OPCSIM with ease. To get started with an ephemeral container with a jupyter lab interface, navigate to your preferred working directory and execute:

$ docker run --rm -p 8888:8888 -e JUPYTER_ENABLE_LAB=yes -v "$PWD":/home/joyvan/work dhhagan/opcsim:latest

Once executed, you should see the url with token in your terminal that will allow you to bring up the jupyter lab instance.

Dependencies

Opcsim is supported for python3.6.1+.

Installation requires scipy, numpy, pandas, matplotlib, and seaborn.

Installation

To install (or upgrade to) the latest stable release:

$ pip install opcsim [--upgrade]

To install the development version directly from GitHub using pip:

$ pip install git+https://github.com/dhhagan/opcsim.git

In addition, you can either clone the repository and install from source or download/unzip the zip file and install from source using poetry:

$ git clone https://github.com/dhhagan/opcsim.git
$ cd /opcsim
$ poetry install

Testing

All tests are automagically run via GitHub actions and Travis.ci. For results of these tests, please click on the link in the above travis badge. In addition, you can run tests locally using poetry.

To run tests locally:

$ poetry run pytest tests

Development

opcsim development takes place on GitHub. Issues and bugs can be submitted and tracked via the GitHub Issue Tracker for this repository. As of v0.5.0, opcsim uses poetry for versioning and managing dependencies and releases.

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

opcsim-1.0.0.tar.gz (24.5 kB view hashes)

Uploaded Source

Built Distribution

opcsim-1.0.0-py3-none-any.whl (26.5 kB view hashes)

Uploaded Python 3

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