Skip to main content

A library for calling different APIs for medical AI usecases.

Project description

MedRouter

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.2.0.tar.gz (7.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.2.0-py3-none-any.whl (9.1 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: medrouter-0.2.0.tar.gz
  • Upload date:
  • Size: 7.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.2.0.tar.gz
Algorithm Hash digest
SHA256 42de55c739682db681e0b6441508922d0f5fade76c471951bd12dddd3b8b9ffd
MD5 37182bb728fcb0ad6c648ef09d7a493e
BLAKE2b-256 86c27abf05416a916ed1c56e6b93d79acbff44b4aedff0a519d643e79622d617

See more details on using hashes here.

File details

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

File metadata

  • Download URL: medrouter-0.2.0-py3-none-any.whl
  • Upload date:
  • Size: 9.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.2.0-py3-none-any.whl
Algorithm Hash digest
SHA256 fb05d7525a882feef8a7a4b86d53257782b83942c49ddcc2f53f81998dd2db56
MD5 00ea92c220d15711d632d456d83a19ad
BLAKE2b-256 34e88f73af2174abba982f4247c33aa5d88f2553b293a88823f5d71a91219b22

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