VolumeInfo

class VolumeInfo(id, name, link, hash, mime, ext, sizeb, created_at, updated_at, meta, path_original, full_storage_url, tags, team_id, workspace_id, project_id, dataset_id, file_meta, figures_count, objects_count, processing_path)[source]

Bases: NamedTuple

NamedTuple with Volume information from Supervisely.

Usage Example:
VolumeInfo(
    id=19581134,
    name="CTChest.nrrd",
    link=None,
    hash="+0K2oFHpqA5dwRKQlhCiiE2qwLNP76Xk0kvhXEh52cs=",
    mime=None,
    ext=None,
    sizeb=46073411,
    created_at="2023-03-29T12:30:37.078Z",
    updated_at="2023-03-29T12:30:37.078Z",
    meta={
        "ACS": "RAS",
        "intensity": {"max": 3071, "min": -3024},
        "windowWidth": 6095,
        "rescaleSlope": 1,
        "windowCenter": 23.5,
        "channelsCount": 1,
        "dimensionsIJK": {"x": 512, "y": 512, "z": 139},
        "IJK2WorldMatrix": [
            0.7617189884185793,
            0,
            0,
            -194.238403081894,
            0,
            0.7617189884185793,
            0,
            -217.5384061336518,
            0,
            0,
            2.5,
            -347.7500000000001,
            0,
            0,
            0,
            1,
        ],
        "rescaleIntercept": 0,
    },
    path_original="/h5af-public/images/original/M/e/7R/vsytec8zX0p.nrrd",
    full_storage_url="https://app.supervisely.com/h5un-public/images/original/M/e/7R/zX0p.nrrd",
    tags=[],
    team_id=435,
    workspace_id=685,
    project_id=18949,
    dataset_id=61803,
    file_meta={
        "mime": "image/nrrd",
        "size": 46073411,
        "type": "int32",
        "extra": {"stride": [1, 512, 262144], "comments": []},
        "sizes": [512, 512, 139],
        "space": "right-anterior-superior",
        "endian": "little",
        "encoding": "gzip",
        "dimension": 3,
        "space origin": [-194.238403081894, -217.5384061336518, -347.7500000000001],
        "space dimension": 3,
        "space directions": [[0.7617189884185793, 0, 0], [0, 0.7617189884185793, 0], [0, 0, 2.5]],
    },
    figures_count=None,
    objects_count=None,
    processing_path='1/1560071'
)

Create new instance of VolumeInfo(id, name, link, hash, mime, ext, sizeb, created_at, updated_at, meta, path_original, full_storage_url, tags, team_id, workspace_id, project_id, dataset_id, file_meta, figures_count, objects_count, processing_path)

Methods

count

Return number of occurrences of value.

index

Return first index of value.

Attributes

created_at

str: Volume creation time.

dataset_id

int: Dataset ID in Supervisely.

ext

str: File extension of the volume.

figures_count

int: Number of figures in the volume.

file_meta

dict: A dictionary containing metadata about the volume file.

full_storage_url

str: Full storage URL of the volume.

hash

str: Volume hash obtained by base64(sha256(file_content)).

id

int: Volume ID in Supervisely.

link

str: Link to volume.

meta

dict: A dictionary containing metadata associated with the volume.

mime

str: MIME type of the volume.

name

str: Volume filename.

objects_count

int: Number of objects in the volume.

path_original

str: Original path of the volume.

processing_path

str: Path to the volume file on the server.

project_id

int: Project ID in Supervisely.

sizeb

int: Size of the volume in bytes.

tags

list: Volume VolumeTag list.

team_id

int: TeamApi ID in Supervisely.

updated_at

str: Time of last volume update.

workspace_id

int: WorkspaceApi ID in Supervisely.

count(value, /)

Return number of occurrences of value.

index(value, start=0, stop=9223372036854775807, /)

Return first index of value.

Raises ValueError if the value is not present.

created_at

str: Volume creation time. e.g. “2019-02-22T14:59:53.381Z”.

dataset_id

int: Dataset ID in Supervisely.

ext

str: File extension of the volume.

figures_count

int: Number of figures in the volume.

file_meta

dict: A dictionary containing metadata about the volume file.

full_storage_url

str: Full storage URL of the volume.

hash

str: Volume hash obtained by base64(sha256(file_content)). Use hash for files that are expected to be stored at Supervisely or your deployed agent.

id

int: Volume ID in Supervisely.

str: Link to volume.

meta

dict: A dictionary containing metadata associated with the volume.

mime

str: MIME type of the volume.

name

str: Volume filename.

objects_count

int: Number of objects in the volume.

path_original

str: Original path of the volume.

processing_path

str: Path to the volume file on the server.

project_id

int: Project ID in Supervisely.

sizeb

int: Size of the volume in bytes.

tags

list: Volume VolumeTag list. e.g. “[{‘entityId’: 19581134, ‘tagId’: 385328, ‘id’: 12259702, ‘value’: ‘some info}]”

team_id

int: TeamApi ID in Supervisely.

updated_at

str: Time of last volume update. e.g. “2019-02-22T14:59:53.381Z”.

workspace_id

int: WorkspaceApi ID in Supervisely.