Skip to main content

smartem-decisions

PyPI version Python Versions License CI

Smart data collection system for cryo-electron microscopy at Diamond Light Source.

Installation

SmartEM Agent (data collection)

pip install smartem-decisions[agent]

Windows executable: Download the latest smartem-agent-windows-vX.Y.Z.exe from GitHub Releases.

SmartEM Backend (API server)

pip install smartem-decisions[backend]

All components

pip install smartem-decisions[all]

Usage

Agent

Watch a directory for EPU output and send data to the backend:

# Basic usage
smartem-agent watch /path/to/epu/output --api-url http://localhost:8000

# Dry run (no API calls)
smartem-agent watch /path/to/epu/output --dry-run

# Verbose output
smartem-agent watch /path/to/epu/output -vv

Parse EPU data without watching:

smartem-agent parse dir /path/to/epu/output
smartem-agent parse session /path/to/EpuSession.dm
smartem-agent parse atlas /path/to/Atlas.dm

Backend

Start the API server and message consumer:

# HTTP API server
python -m smartem_backend.api_server

# Message queue consumer
python -m smartem_backend.consumer -v

Components

Package Description
smartem_agent Data collection agent that monitors EPU output
smartem_backend Core backend with HTTP API and message queue processing
smartem_common Shared schemas, types, and utilities

Installation Extras

Extra Description
[agent] Agent dependencies (watchdog, lxml)
[backend] Backend dependencies (FastAPI, SQLAlchemy, Pika)
[common] Core schemas only (Pydantic)
[images] Image processing (Pillow, mrcfile, tifffile)
[dev] Development tools (pytest, ruff, pyright)
[all] All dependencies

Development

# Install with dev dependencies
pip install -e ".[dev]"

# Run tests
pytest

# Lint
ruff check src/
ruff format --check src/

# Type check
pyright

Documentation

Links

License

Apache-2.0

Download files

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

Source Distribution

smartem_decisions-0.1.1.tar.gz (344.7 kB view details)

Uploaded Source

Built Distribution

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

smartem_decisions-0.1.1-py3-none-any.whl (156.9 kB view details)

Uploaded Python 3

File details

Details for the file smartem_decisions-0.1.1.tar.gz.

File metadata

  • Download URL: smartem_decisions-0.1.1.tar.gz
  • Upload date:
  • Size: 344.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for smartem_decisions-0.1.1.tar.gz
Algorithm Hash digest
SHA256 3a96c1df7671e32e19f5acb45cc29eee2fa510e5788882c72f14c23a728eee48
MD5 6c308ae8df64b3ac325269241878d4b5
BLAKE2b-256 5bbefc558cf5f6763fc47dd530273dbb4b011f669d5946db1d5dad799ded44c3

See more details on using hashes here.

Provenance

The following attestation bundles were made for smartem_decisions-0.1.1.tar.gz:

Publisher: release-smartem-decisions.yml on DiamondLightSource/smartem-decisions

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file smartem_decisions-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for smartem_decisions-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0c4d9748a100a568b980b6870f5edaf4add53b6a7f13eff836160740d93fa162
MD5 d1de27dc523f35015b660a7e668b1f7c
BLAKE2b-256 1b66d44e477552288be16b2407dfa0ffbc58bf574ef0296f1da2434b1ae5d107

See more details on using hashes here.

Provenance

The following attestation bundles were made for smartem_decisions-0.1.1-py3-none-any.whl:

Publisher: release-smartem-decisions.yml on DiamondLightSource/smartem-decisions

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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