Skip to main content

Official Python SDK for Picsha AI - Store, Encode, Understand.

Project description

Picsha AI Python SDK 🐍

The official Python client for Picsha AI. Designed specifically for data scientists, computational biologists, and ML engineers.

Installation

We recommend using poetry:

poetry add picsha

Or pip:

pip install picsha

Quickstart

import picsha

client = picsha.Client(api_key="sk_your_key_here")

# 1. Semantic Search
results = client.search(
    query="fluorescent cancer cell cultures", 
    mode="ai"  # Hybrid Vector Search
)

# 2. Get transformed URLs for ML pipelines
for asset in results.assets:
    url = asset.generate_url(width=512, height=512, format="webp")
    print(url)

Asynchronous Support

For high-throughput workloads, an AsyncClient is included out-of-the-box:

import picsha
import asyncio

async def main():
    async with picsha.AsyncClient(api_key="sk_your_key_here") as client:
        result = await client.search(query="cancer cells", mode="ai")
        print(f"Found {result.total_count} assets.")

asyncio.run(main())

See the notebooks/ directory for full examples integrating with Pandas, PyTorch, and SciPy.

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

picsha-0.1.1.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

picsha-0.1.1-py3-none-any.whl (4.6 kB view details)

Uploaded Python 3

File details

Details for the file picsha-0.1.1.tar.gz.

File metadata

  • Download URL: picsha-0.1.1.tar.gz
  • Upload date:
  • Size: 3.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.5 Darwin/25.4.0

File hashes

Hashes for picsha-0.1.1.tar.gz
Algorithm Hash digest
SHA256 160fa49eb3b2bf5449f00b6443cbac329b23be2d96646cc55b7590b71ee01c6b
MD5 9b5920d612fb6c5d44b6afea81523171
BLAKE2b-256 79bda92b8b661bfce5b149f32049c4fb32bc02cbc0cb23e78c70e1aae4445b4e

See more details on using hashes here.

File details

Details for the file picsha-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: picsha-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/2.4.1 CPython/3.14.5 Darwin/25.4.0

File hashes

Hashes for picsha-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e17781999d384bbb92ba3ef32d3255a32b27c18e2a02d5c9bf7da6a1954d4039
MD5 aa9673e8993adcd243cb3f0e78b4da94
BLAKE2b-256 d1aaab46b556ea4e0c8b36d1e5d17303f874e7cab048889e9d4d732c50a30241

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