The Python SDK for using IntelliProve.
Reason this release was yanked:
depracated
Project description
IntelliProve Python SDK
Requirements
- Python ^3.9
Installation
pip install intelliprove
Documentation
You can find our SDK documentation here.
Release Notes
1.2
New features
- Added
UnprocessableVideoResponse
model andVideoProcessingFailedException
exception:
The new model
UnprocessableVideoResponse
provides extra information about why a certain video did not successfully process.
This new information is returned inside the newVideoProcessingFailedException
exception, which gets throw from theget_results
method.
Updates
- Refactor of
Quality
dataclass:
The following properties for the
Quality
model have been renamed:
message
=>prompt
Deprecated features
How to Upgrade
- Ensure you are using the new property
prompt
from theQuality
model - Ensure you catch the new
VideoProcessingFailedException
when calling theget_results
method. Additionally you can read out theresponse
property of this exception to provide feedback to the end-user.
Example usage
import os
from pathlib import Path
from intelliprove.api import IntelliproveApi, IntelliproveApiSettings, Biomarkers, Quality
# define api key and settings
apikey = os.environ.get('apikey')
settings = IntelliproveApiSettings(
base_url=''
)
# init api
api = IntelliproveApi(apikey, settings)
# define the path of the video you want to upload
video_path = Path('./mydir/example.mp4')
image_path = Path('./mydir/example.png')
# manually check quality of a video of image
quality: Quality = api.check_conditions(video_path)
quality: Quality = api.check_conditions(image_path)
# Optional: define the performer and patient
performer: str = 'performer-a'
patient: str = 'patient-1'
# upload video to IntelliProve
# performer and patient are optional
uuid: str = api.upload(video_path)
# or
uuid: str = api.upload(video_path, performer=performer, patient=patient)
# get the results of the uploaded video
results: Biomarkers = api.get_results(uuid)
Dataclasses
- Biomarkers
- contains the results of an uploaded video
- Quality
- contains the quality parameters of a video or image
Exceptions
- ImageQualityException
- MediaException
- InvalidUuidException
- VideoProcessingFailedException
- ApiException
- ApiNotFoundException
- ApiForbiddenException
- ApiErrorException
- ApiResultNotAvailable
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
intelliprove-1.2.0.tar.gz
(8.6 kB
view hashes)
Built Distribution
Close
Hashes for intelliprove-1.2.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8e30a1823e088141e927b15a72484b32d39a098d0d0a2c1c52761bd264d20e74 |
|
MD5 | 268f2ae505936648b19f008ab6fc0ceb |
|
BLAKE2b-256 | 531a436e97f02bbfbe963df66b4f3bc92eca7607183523a315cfc74c03a25926 |