Skip to main content

Define routines as structured algorithmic workflows

Project description

routix

Routix is a lightweight Python toolkit for designing and executing structured algorithmic workflows.

Key Features

  • Subroutine-based execution control: Flexible workflow management via SubroutineController
    • Context-aware logging: Detailed logging with routine context traceability via MethodContextManager
  • Structured flow validation: Validate workflow definitions with SubroutineFlowValidator
  • Dot-accessible configuration/data objects: Manage hierarchical data and configuration with DynamicDataObject
  • Experiment summary and timing: Manage experiment results and timing with ExperimentSummary, ElapsedTimer, etc.
  • Extensible runner base classes: Build custom workflow runners (single/multi/concurrent) in src/routix/runner/
  • Metric time series management: Collect and store time series data during experiments with MetricTimeSeries and NamedTimeSeriesStore
  • Utilities: Tools for saving results/configuration as YAML/JSON and more

Subroutine Flow Data Format

Routix executes workflows defined as structured lists of dictionaries. Each step is clearly specified with method names and parameters.

- method: initialize
- method: repeat
  params:
    n_repeats: 3
    routine_data:
      - method: sample_method
        params:
          value: 42

See subroutine_flow_data.md for details.

Runner Base Classes

  • SingleInstanceRunner: Abstract base for running a single problem instance
  • MultiInstanceRunner: Abstract base for running multiple instances in sequence
  • MultiInstanceConcurrentRunner: Abstract base for running multiple instances concurrently (in parallel)

All runners are designed for subclassing and method overriding to fit your experiment patterns.

Note: InstanceSetRunner is a deprecated name. Please use MultiInstanceRunner instead.

Metric Time Series

  • MetricTimeSeries: Manages (timestamp, value, note) time series data
  • NamedTimeSeriesStore: Stores and manages multiple named MetricTimeSeries

This enables structured recording of experiment metrics, with export to YAML/JSON supported.

Utilities

  • object_to_yaml, object_to_json: Save experiment results and configuration to files
  • Additional helpers for experiment management

Testing

Unit tests for all major components are included in the tests/ directory. Run all tests with pytest.


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

routix-0.0.11.tar.gz (30.0 kB view details)

Uploaded Source

Built Distribution

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

routix-0.0.11-py3-none-any.whl (25.9 kB view details)

Uploaded Python 3

File details

Details for the file routix-0.0.11.tar.gz.

File metadata

  • Download URL: routix-0.0.11.tar.gz
  • Upload date:
  • Size: 30.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.2

File hashes

Hashes for routix-0.0.11.tar.gz
Algorithm Hash digest
SHA256 fbc949bac9a5fd18eb27c8ea8b170e2f23bd2c3f91f8371f2a77ff81b8135516
MD5 eee573625893308bed3cb54f0edecf1a
BLAKE2b-256 25e869e8cadef5731b9af2865e4aa32d7307653268cf2e4b9bb58a5108cf0a50

See more details on using hashes here.

File details

Details for the file routix-0.0.11-py3-none-any.whl.

File metadata

  • Download URL: routix-0.0.11-py3-none-any.whl
  • Upload date:
  • Size: 25.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.7.2

File hashes

Hashes for routix-0.0.11-py3-none-any.whl
Algorithm Hash digest
SHA256 c0be3ca3da214edcf33c41d35b5ba87e8cfca7238643c2c0c208e7ef542ab342
MD5 c3cd52241bff505733c522a4f610b5be
BLAKE2b-256 8de7be394fb25965a537081aac41525839ffcca741cdbe23c18b221246979b7e

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