The sample segments Ink Lens reads are open data, and each one reads straight from its URL in your own tool. The page is also an API and an MCP server.
https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/9.366um-1.2m-113keV-volume-20250821151531.zarr# pip install "zarr>=3" fsspec aiohttp
import zarr
root = zarr.open_group("https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/9.366um-1.2m-113keV-volume-20250821151531.zarr", mode="r") # OME-Zarr, zarr v2
a = root["0"] # level 0 is full resolution; level L is 2**L times coarser
print(a.shape, a.dtype, a.chunks)
block = a[0:64, 2800:2864, 2900:2964] # (z, y, x); reads only the chunks it touches# pip install "vesuvius[volume-only]"
from vesuvius import Volume
v = Volume(type="zarr", path="https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/9.366um-1.2m-113keV-volume-20250821151531.zarr/0") # one pyramid level
block = v[0:64, 2800:2864, 2900:2964]curl -s https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/9.366um-1.2m-113keV-volume-20250821151531.zarr/.zattrs # OME multiscales metadata
curl -s https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/9.366um-1.2m-113keV-volume-20250821151531.zarr/0/.zarray # one level: shape, chunks, dtype, codechttps://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/mesh/20260220213127-on-20250821151531-9.366um.tifxyz# pip install numpy tifffile
import io, json, urllib.request
import numpy as np, tifffile
T = "https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/mesh/20260220213127-on-20250821151531-9.366um.tifxyz"
meta = json.load(urllib.request.urlopen(T + "/meta.json")) # scale, bbox, format
get = lambda c: tifffile.imread(io.BytesIO(urllib.request.urlopen(f"{T}/{c}.tif").read()))
xyz = np.stack([get(c) for c in "xyz"], -1) # xyz[i, j] = (x, y, z) in scan voxels; -1 = no surfacehttps://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/2.403um-0.22m-77keV-volume-20260319124803.zarr# pip install "zarr>=3" fsspec aiohttp
import zarr
root = zarr.open_group("https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/2.403um-0.22m-77keV-volume-20260319124803.zarr", mode="r") # OME-Zarr, zarr v2
a = root["0"] # level 0 is full resolution; level L is 2**L times coarser
print(a.shape, a.dtype, a.chunks)
block = a[0:64, 11200:11264, 11600:11664] # (z, y, x); reads only the chunks it touches# pip install "vesuvius[volume-only]"
from vesuvius import Volume
v = Volume(type="zarr", path="https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/2.403um-0.22m-77keV-volume-20260319124803.zarr/0") # one pyramid level
block = v[0:64, 11200:11264, 11600:11664]curl -s https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/2.403um-0.22m-77keV-volume-20260319124803.zarr/.zattrs # OME multiscales metadata
curl -s https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/surface-volumes/2.403um-0.22m-77keV-volume-20260319124803.zarr/0/.zarray # one level: shape, chunks, dtype, codechttps://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/mesh/20260220213127-on-20260319124803-2.403um.tifxyz# pip install numpy tifffile
import io, json, urllib.request
import numpy as np, tifffile
T = "https://vesuvius-challenge-open-data.s3.us-east-1.amazonaws.com/PHerc0841/segments/20260220213127-w00/mesh/20260220213127-on-20260319124803-2.403um.tifxyz"
meta = json.load(urllib.request.urlopen(T + "/meta.json")) # scale, bbox, format
get = lambda c: tifffile.imread(io.BytesIO(urllib.request.urlopen(f"{T}/{c}.tif").read()))
xyz = np.stack([get(c) for c in "xyz"], -1) # xyz[i, j] = (x, y, z) in scan voxels; -1 = no surfacehttps://huggingface.co/spaces/SharpMeow/ink-lens# pip install gradio_client
from gradio_client import Client
client = Client("SharpMeow/ink-lens")
result = client.predict(sample_id="0841-w00", size=640, reader="d9v2", windows=3, api_name="/lens_sample")# pip install gradio_client
from gradio_client import Client
client = Client("SharpMeow/ink-lens")
result = client.predict(api_name="/list_samples")# pip install gradio_client
from gradio_client import Client
client = Client("SharpMeow/ink-lens")
result = client.predict(sample_id="0841-w00", models="ink_9um-s42,reader-v3,hecate-9.6", size=384, scan="2.4", centers="0", steps="1", api_name="/compare_sample")# pip install gradio_client
from gradio_client import Client
client = Client("SharpMeow/ink-lens")
result = client.predict(api_name="/list_models")URL=https://sharpmeow-ink-lens.hf.space
EVENT=$(curl -s -X POST $URL/gradio_api/call/lens_sample -H 'Content-Type: application/json' \
-d '{"data": ["0841-w00", 640, "d9v2", 3]}' | python3 -c 'import json,sys; print(json.load(sys.stdin)["event_id"])')
curl -sN $URL/gradio_api/call/lens_sample/$EVENT{
"mcpServers": {
"ink-lens": {
"url": "https://sharpmeow-ink-lens.hf.space/gradio_api/mcp/sse"
}
}
}
Tool list: https://sharpmeow-ink-lens.hf.space/gradio_api/mcp/schema