Skip to main content

in silico fate mapping

License BSD-3 PyPI Python Version tests codecov napari hub

Interactive in silico fate mapping from tracking data.

This napari plugin estimates the cell fates from tracking data by building a radial regression model per time point. The user can select an area of interest using a Points layer; the algorithm will advent the probed coordinates forward (or backward) in time, showing the estimated fate.

Video example below:

https://user-images.githubusercontent.com/21022743/216478216-89c1c35f-2ce4-44e8-adb8-9aeea75b5833.mp4

Installation

We suggest you create a fresh conda environment to avoid conflicts with your existing package. To do this, you need to:

conda create -n fatemap python=3.11
conda activate fatemap

And then, you can install in-silico-fate-mapping via pip and other additional useful packages:

pip install napari-ome-zarr napari[all] in-silico-fate-mapping

To install the latest development version :

pip install git+https://github.com/royerlab/in-silico-fate-mapping.git

IO file format

This plugin does not depend on a specific file format, the only requirement is using a Track layer from napari.

Despite this, we ship a reader and writer interface. It supports .csv files with the following reader track_id, t, (z), y, x, z is optional. Such that each tracklet has a unique track_id and it's composed of a sequence o time and spatial coordinates.

This is extremely similar to how napari store tracks, more information can be found here.

Divisions are not supported at the moment.

Usage Example

Minimal example

Minimal example using a track file following the convention described above.

import napari
import pandas as pd
from in_silico_fate_mapping.fate_mapping import FateMapping

tracks = pd.read_csv("tracks.csv")

fate_map = FateMapping(radius=5, n_samples=25, bind_to_existing=False, sigma=1)
fate_map.data = tracks[["track_id", "t", "z", "y", "x"]]

source = tracks[tracks["t"] == 0].sample(n=1)

tracks = fate_map(source[["t", "z", "y", "x"]])

napari.view_tracks(tracks)
napari.run()

Zebrahub example

Zebrafish embryo tail example. This example requires the package napari-ome-zarr.

import napari
import pandas as pd
from in_silico_fate_mapping import FateMappingWidget

image_path = "http://public.czbiohub.org/royerlab/zebrahub/imaging/single-objective/ZSNS001_tail.ome.zarr"
tracks_path = "http://public.czbiohub.org/royerlab/zebrahub/imaging/single-objective/ZSNS001_tail_tracks.csv"

viewer = napari.Viewer()
viewer.window.add_dock_widget(FateMappingWidget(viewer))

viewer.open(image_path, plugin="napari-ome-zarr")

tracks = pd.read_csv(tracks_path)
viewer.add_tracks(tracks[["track_id", "t", "z", "y", "x"]])
viewer.add_points(name="Markers", ndim=4)

napari.run()

Citing

If used please cite:

@article{lange2023zebrahub,
  title={Zebrahub-Multimodal Zebrafish Developmental Atlas Reveals the State Transition Dynamics of Late Vertebrate Pluripotent Axial Progenitors},
  author={Lange, Merlin and Granados, Alejandro and VijayKumar, Shruthi and Bragantini, Jordao and Ancheta, Sarah and Santhosh, Sreejith and Borja, Michael and Kobayashi, Hirofumi and McGeever, Erin and Solak, Ahmet Can and others},
  journal={bioRxiv},
  pages={2023--03},
  year={2023},
  publisher={Cold Spring Harbor Laboratory}
}

Issues

If you encounter any problems, please file an issue along with a detailed description.

Metadata

Release files for in-silico-fate-mapping 0.1.3.1

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

Source distribution (sdist)

Source distribution for in-silico-fate-mapping 0.1.3.1
File Size Uploaded
in_silico_fate_mapping-0.1.3.1.tar.gz 24.7 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for in-silico-fate-mapping 0.1.3.1
File Interpreter ABI Platform
in_silico_fate_mapping-0.1.3.1-py3-none-any.whl Python 3 none any Details

Total release size: 47.8 kB

Release files / in_silico_fate_mapping-0.1.3.1.tar.gz

Download URL in_silico_fate_mapping-0.1.3.1.tar.gz
Size 24.7 kB
Tags Source
SHA-256 checksum
How to use checksums
efd39ca2c7e6170c78b19151a6ce97f6c803cc3fe84819ed2c36b9631a36a66a
BLAKE2b-256 checksum
How to use checksums
92b903d715c063b5da1f47a05b9e03bc474a568c08300672d12c4d8bcdde7445
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.0

Release files / in_silico_fate_mapping-0.1.3.1-py3-none-any.whl

Download URL in_silico_fate_mapping-0.1.3.1-py3-none-any.whl
Size 23.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
3ba9cafae71296cd12ae8cd8adb1bdfc0572a95fea40ffeea4fd8bd99c28a599
BLAKE2b-256 checksum
How to use checksums
c16b59f55ccbae9fa27a8ea127c965e944e3d62186e6637a69f9f4c12f218355
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.14.0

Release history Release notifications | RSS feed

This release

0.1.3.1 This release

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

1 release file

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