Skip to main content

A library for calling different APIs for medical AI usecases.

Project description

MedRouter Banner

MedRouter is a Python library designed to facilitate the interaction with various APIs for medical AI applications. Currently, it supports segmentation models, with plans to expand into other domains soon. This project is powered by PYCAD.

Features

  • Easy API Integration: Simplifies the process of calling different APIs hosted on external servers.
  • Segmentation Models: Supports segmentation models with more models and domains to be added in the future.
  • Error Handling: Provides robust error handling to ensure smooth operation.

Installation

You can install MedRouter using pip:

pip install medrouter

Usage

Here's a quick example of how to use the MedRouter library:

from medrouter import MedRouter

# Initialize the client with your API key
client = MedRouter(api_key="your_api_key")

# Run a segmentation model
predictions = client.segmentation.create(
    source="path_to_file",
    model="total-segmentator"
)

print(predictions)

Available Models

  • total-segmentator: A model for comprehensive segmentation tasks.

Error Handling

MedRouter provides specific exceptions to handle common errors:

  • ModelNotFoundError: Raised when the specified model is not found.
  • InferenceError: Raised when there is an error during the inference process.
  • APIKeyError: Raised when there is an issue with the API key, such as it being missing or incorrect.

Contributing

We welcome contributions to expand the capabilities of MedRouter. Please feel free to submit issues or pull requests.

License

This project is licensed under the Apache 2.0 License. See the LICENSE file for more details.

Contact

For more information, please contact us at contact@pycad.co.


MedRouter is a project by PYCAD, dedicated to advancing medical AI technologies.

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

medrouter-0.4.0.tar.gz (8.8 kB view details)

Uploaded Source

Built Distribution

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

medrouter-0.4.0-py3-none-any.whl (10.1 kB view details)

Uploaded Python 3

File details

Details for the file medrouter-0.4.0.tar.gz.

File metadata

  • Download URL: medrouter-0.4.0.tar.gz
  • Upload date:
  • Size: 8.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.14

File hashes

Hashes for medrouter-0.4.0.tar.gz
Algorithm Hash digest
SHA256 fd68bf2c559d088e4e4bd9e279861aad981d858282b5d721985f3984509d3e2d
MD5 99a9254320e7c7d98bf5c1bee0f356ab
BLAKE2b-256 e001ed30141a8539760421ec5895846ad02cd2deaa6bcc3b6aa1509f3efa72ae

See more details on using hashes here.

File details

Details for the file medrouter-0.4.0-py3-none-any.whl.

File metadata

  • Download URL: medrouter-0.4.0-py3-none-any.whl
  • Upload date:
  • Size: 10.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.0 CPython/3.10.14

File hashes

Hashes for medrouter-0.4.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4e889589566acd1f6bad4af0dc6bbdefe2661c61145321070248609d3ecec0ea
MD5 3844ede233cf9f148a2e31fbda06ba62
BLAKE2b-256 7db3564c5155d589d3035fe7532684571c4d33a2b9301adea8111a3e2751a9be

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