Skip to main content

scigantic-facebase

Search FaceBase, the craniofacial research data hub, and read its open-access data from Python.

FaceBase holds about 1,070 open datasets: micro-CT and light-sheet imaging, ChIP-seq and RNA-seq tracks, expression tables and more, from mouse, zebrafish, human and other models. This package is a typed layer over FaceBase's open metadata API and file store. No key or login is needed.

pip install scigantic-facebase

Use

import scigantic_facebase as fb

hits = fb.search("zebrafish thyroid microCT")     # newest first
ds = hits[0]
print(ds.title, ds.doi_url)
print(fb.cite(ds))

files = fb.files(ds)                               # size, MD5, download URL
fb.download(files[0], "data/")                     # MD5-checked

Search matches every word against the whole record, and treats "zebrafish" and "Danio rerio", "mouse" and "Mus musculus" as the same thing.

Read a micro-CT scan without downloading it

Many micro-CT datasets are a zip of TIFF slices. A zip keeps its directory at the end, so one slice costs one HTTP range request.

stack = fb.microct.open_stack(files[0])
len(stack)                  # 596 slices
stack.voxel_size_um         # 10.5, from the scan log
img = stack.read_slice(300)
vol = stack.volume(step=10) # every 10th slice, (z, y, x)
stack.bytes_fetched         # a few MB of a 49 MB file

fb.microct.thyroid_atlas() lists the zebrafish thyroid-hormone atlas: 81 head scans from 12 to 25 mm standard length, raised hypothyroid, euthyroid or hyperthyroid.

fb.open_remote(file) gives any FaceBase file as a seekable file object backed by range requests, which zipfile, tifffile and h5py accept.

What is not here

Protected human-subjects datasets sit behind FaceBase's data access request. Their metadata is public and fb.search(include_protected=True) lists them, but reading their files raises FacebaseAccessError.

Terms of use

Copyright to FaceBase data belongs to the contributing investigators. FaceBase's Terms of Use ask users to cite the dataset, acknowledge FaceBase, and send other people to FaceBase instead of circulating downloaded files. fb.cite() produces the citation. This package fetches from FaceBase on request and does not mirror anything.

License

MIT-0 for this code. The data carries its own terms.

Metadata

Release files for scigantic-facebase 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for scigantic-facebase 0.1.0
File Size Uploaded Provenance Actions
scigantic_facebase-0.1.0.tar.gz 14.8 kB Without provenance Details for scigantic_facebase-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for scigantic-facebase 0.1.0
File Interpreter ABI Platform Actions
scigantic_facebase-0.1.0-py3-none-any.whl Python 3 none any Details for scigantic_facebase-0.1.0-py3-none-any.whl

Total release size: 28.8 kB

Release files / scigantic_facebase-0.1.0.tar.gz

Download URL scigantic_facebase-0.1.0.tar.gz
Size 14.8 kB
Tags Source
SHA-256 checksum
How to use checksums
85fd5558c63aa53a5ad2cff378aa5fd3e540b5ba67732232853386f93a27c887
BLAKE2b-256 checksum
How to use checksums
ae118e617e4ed33378613140f6dac671ecd0e7e675800ef392ce9ba1f4c7b791
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.17

Release files / scigantic_facebase-0.1.0-py3-none-any.whl

Download URL scigantic_facebase-0.1.0-py3-none-any.whl
Size 14.0 kB
Tags Python 3
SHA-256 checksum
How to use checksums
713c413594548c7a0568c71a32b8330b41f1327815eb0874980c1974da0cde5e
BLAKE2b-256 checksum
How to use checksums
d0afb40cc1adce7e33528f6a4f578a8bb21c587ea7ffe892a181643c457fad3e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.17

Security for scigantic-facebase 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page