Skip to main content

A library to preprocess image data.

Project description

Paidiverpy

lifecycle License Documentation DOI Pypi

Paidiverpy is a Python package designed to create pipelines for preprocessing image data for biodiversity analysis.

Documentation

The official documentation is hosted on ReadTheDocs.org: https://paidiverpy.readthedocs.io/

Installation

To install paidiverpy, run:

pip install paidiverpy

Build from Source

  1. Clone the repository:

    # ssh
    git clone git@github.com:paidiver/paidiverpy.git
    
    # https
    # git clone https://github.com/paidiver/paidiverpy.git
    
    cd paidiverpy
  2. (Optional) Create a Python virtual environment to manage dependencies separately from other projects. For example, using conda:

    conda env create -f environment.yml
    conda activate Paidiverpy
  3. Install the paidiverpy package:

    pip install -e .

Usage

You can run your preprocessing pipeline using Paidiverpy in several ways, typically requiring just one to three lines of code:

Python Package

Install the package and utilize it in your Python scripts.

# Import the Pipeline class
from paidiverpy.pipeline import Pipeline

# Instantiate the Pipeline class with the configuration file path
# Please refer to the documentation for the configuration file format
pipeline = Pipeline(config_file_path="../examples/config_files/config_simple2.yml")

# Run the pipeline
pipeline.run()
# You can export the output images to the specified output directory
pipeline.save_images(image_format="png")

Command Line Interface (CLI)

Execute the package via the command line.

paidiverpy -c "../examples/config_files/config_simple2.yml"

Docker

You can run Paidiverpy using Docker by either building the container locally or pulling a pre-built image from GitHub Container Registry (GHCR) or Docker Hub.

  1. Build the container locally:

    git clone git@github.com:paidiver/paidiverpy.git
    cd paidiverpy
    docker build -t paidiverpy .
  2. Pull from GitHub Container Registry (GHCR):

    docker pull ghcr.io/paidiver/paidiverpy:latest
    docker tag ghcr.io/paidiver/paidiverpy:latest paidiverpy:latest
  3. Pull from Docker Hub:

    docker pull soutobias/paidiverpy:latest
    docker tag soutobias/paidiverpy:latest paidiverpy:latest

To run the container, use the following command:

docker run --rm \
  -v <INPUT_PATH>:/app/input/ \
  -v <OUTPUT_PATH>:/app/output/ \
  -v <METADATA_PATH>:/app/metadata/ \
  -v <CONFIG_DIR>:/app/config_files/ \
  paidiverpy -c /app/examples/config_files/<CONFIG_FILE>

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

paidiverpy-0.1.2.tar.gz (35.9 MB view details)

Uploaded Source

Built Distribution

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

paidiverpy-0.1.2-py3-none-any.whl (74.9 kB view details)

Uploaded Python 3

File details

Details for the file paidiverpy-0.1.2.tar.gz.

File metadata

  • Download URL: paidiverpy-0.1.2.tar.gz
  • Upload date:
  • Size: 35.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for paidiverpy-0.1.2.tar.gz
Algorithm Hash digest
SHA256 9b4145561e05ffb854dca446da8490cbf2705a214b7d1ebeed16983c052512a0
MD5 41d545c3c779e5b646424ae1c307b00c
BLAKE2b-256 656dc46c572dff5e091ea5403deba1bf486cf0f4050b862689959832cb621311

See more details on using hashes here.

File details

Details for the file paidiverpy-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: paidiverpy-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 74.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for paidiverpy-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6cf9253033cf902700e325e7265808601042f4e6630cb507e187b194766d06c3
MD5 d114c4883bc054dd815157cb1e506b7c
BLAKE2b-256 6f613fd6bd178b3dd1067cb9ab02e00cfd352c621968bd86dc20d88a7c4f1c51

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