aliby


Namealiby JSON
Version 0.1.63 PyPI version JSON
download
home_page
SummaryProcess and analyse live-cell imaging data
upload_time2023-06-28 18:03:55
maintainer
docs_urlNone
authorAlan Munoz
requires_python>=3.8,<3.11
license
keywords
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ALIBY (Analyser of Live-cell Imaging for Budding Yeast)

[![docs](https://readthedocs.org/projects/aliby/badge/?version=master)](https://aliby.readthedocs.io/en/latest)
[![PyPI version](https://badge.fury.io/py/aliby.svg)](https://badge.fury.io/py/aliby)
[![pipeline](https://gitlab.com/aliby/aliby/badges/master/pipeline.svg?key_text=master)](https://gitlab.com/aliby/aliby/-/pipelines)
[![dev pipeline](https://gitlab.com/aliby/aliby/badges/dev/pipeline.svg?key_text=dev)](https://gitlab.com/aliby/aliby/-/commits/dev)
[![coverage](https://gitlab.com/aliby/aliby/badges/dev/coverage.svg)](https://gitlab.com/aliby/aliby/-/commits/dev)

End-to-end processing of cell microscopy time-lapses. ALIBY automates segmentation, tracking, lineage predictions, post-processing and report production. It leverages the existing Python ecosystem and open-source scientific software available to produce seamless and standardised pipelines.

## Quickstart Documentation
Installation of [VS Studio](https://visualstudio.microsoft.com/downloads/#microsoft-visual-c-redistributable-for-visual-studio-2022) Native MacOS support for is under work, but you can use containers (e.g., Docker, Podman) in the meantime.

To analyse local data
 ```bash
pip install aliby 
 ```
 Add any of the optional flags `omero` and `utils` (e.g., `pip install aliby[omero, utils]`). `omero` provides tools to connect with an OMERO server and `utils` provides visualisation, user interface and additional deep learning tools.
  
See our [installation instructions]( https://aliby.readthedocs.io/en/latest/INSTALL.html ) for more details.

### CLI

If installed via poetry, you have access to a Command Line Interface (CLI)

 ```bash
aliby-run --expt_id EXPT_PATH --distributed 4 --tps None
 ```

And to run Omero servers, the basic arguments are shown:
 ```bash
 aliby-run --expt_id XXX --host SERVER.ADDRESS --user USER --password PASSWORD 
 ```

The output is a folder with the original logfiles and a set of hdf5 files, one with the results of each multidimensional inside.

For more information, including available options, see the page on [running the analysis pipeline](https://aliby.readthedocs.io/en/latest/PIPELINE.html)

## Using specific components

### Access raw data

ALIBY's tooling can also be used as an interface to OMERO servers, for example, to fetch a brightfield channel.
 ```python
from aliby.io.omero import Dataset, Image

server_info= {
            "host": "host_address",
            "username": "user",
            "password": "xxxxxx"}
expt_id = XXXX
tps = [0, 1] # Subset of positions to get.

with Dataset(expt_id, **server_info) as conn:
    image_ids = conn.get_images()

#To get the first position
with Image(list(image_ids.values())[0], **server_info) as image:
    dimg = image.data
    imgs = dimg[tps, image.metadata["channels"].index("Brightfield"), 2, ...].compute()
    # tps timepoints, Brightfield channel, z=2, all x,y
```

### Tiling the raw data

A `Tiler` object performs trap registration. It may be built in different ways but the simplest one is using an image and a the default parameters set.

```python
from aliby.tile.tiler import Tiler, TilerParameters
with Image(list(image_ids.values())[0], **server_info) as image:
    tiler = Tiler.from_image(image, TilerParameters.default())
    tiler.run_tp(0)
```

The initialisation should take a few seconds, as it needs to align the images
in time.

It fetches the metadata from the Image object, and uses the TilerParameters values (all Processes in aliby depend on an associated Parameters class, which is in essence a dictionary turned into a class.)

#### Get a timelapse for a given tile (remote connection)
```python
fpath = "h5/location"

tile_id = 9
trange = range(0, 10)
ncols = 8

riv = remoteImageViewer(fpath)
trap_tps = [riv.tiler.get_tiles_timepoint(tile_id, t) for t in trange] 

# You can also access labelled traps
m_ts = riv.get_labelled_trap(tile_id=0, tps=[0])

# And plot them directly
riv.plot_labelled_trap(trap_id=0, channels=[0, 1, 2, 3], trange=range(10))
```

Depending on the network speed can take several seconds at the moment.
For a speed-up: take fewer z-positions if you can.

#### Get the tiles for a given time point
Alternatively, if you want to get all the traps at a given timepoint:

```python
timepoint = (4,6)
tiler.get_tiles_timepoint(timepoint, channels=None,
                                z=[0,1,2,3,4])
```


### Contributing
See [CONTRIBUTING](https://aliby.readthedocs.io/en/latest/INSTALL.html) on how to help out or get involved.

            

Raw data

            {
    "_id": null,
    "home_page": "",
    "name": "aliby",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.8,<3.11",
    "maintainer_email": "",
    "keywords": "",
    "author": "Alan Munoz",
    "author_email": "alan.munoz@ed.ac.uk",
    "download_url": "https://files.pythonhosted.org/packages/f5/ac/d2198a269ac06fb61ec5664217c80f2fd5a565a51c4d558fee8b44f7508f/aliby-0.1.63.tar.gz",
    "platform": null,
    "description": "# ALIBY (Analyser of Live-cell Imaging for Budding Yeast)\n\n[![docs](https://readthedocs.org/projects/aliby/badge/?version=master)](https://aliby.readthedocs.io/en/latest)\n[![PyPI version](https://badge.fury.io/py/aliby.svg)](https://badge.fury.io/py/aliby)\n[![pipeline](https://gitlab.com/aliby/aliby/badges/master/pipeline.svg?key_text=master)](https://gitlab.com/aliby/aliby/-/pipelines)\n[![dev pipeline](https://gitlab.com/aliby/aliby/badges/dev/pipeline.svg?key_text=dev)](https://gitlab.com/aliby/aliby/-/commits/dev)\n[![coverage](https://gitlab.com/aliby/aliby/badges/dev/coverage.svg)](https://gitlab.com/aliby/aliby/-/commits/dev)\n\nEnd-to-end processing of cell microscopy time-lapses. ALIBY automates segmentation, tracking, lineage predictions, post-processing and report production. It leverages the existing Python ecosystem and open-source scientific software available to produce seamless and standardised pipelines.\n\n## Quickstart Documentation\nInstallation of [VS Studio](https://visualstudio.microsoft.com/downloads/#microsoft-visual-c-redistributable-for-visual-studio-2022) Native MacOS support for is under work, but you can use containers (e.g., Docker, Podman) in the meantime.\n\nTo analyse local data\n ```bash\npip install aliby \n ```\n Add any of the optional flags `omero` and `utils` (e.g., `pip install aliby[omero, utils]`). `omero` provides tools to connect with an OMERO server and `utils` provides visualisation, user interface and additional deep learning tools.\n  \nSee our [installation instructions]( https://aliby.readthedocs.io/en/latest/INSTALL.html ) for more details.\n\n### CLI\n\nIf installed via poetry, you have access to a Command Line Interface (CLI)\n\n ```bash\naliby-run --expt_id EXPT_PATH --distributed 4 --tps None\n ```\n\nAnd to run Omero servers, the basic arguments are shown:\n ```bash\n aliby-run --expt_id XXX --host SERVER.ADDRESS --user USER --password PASSWORD \n ```\n\nThe output is a folder with the original logfiles and a set of hdf5 files, one with the results of each multidimensional inside.\n\nFor more information, including available options, see the page on [running the analysis pipeline](https://aliby.readthedocs.io/en/latest/PIPELINE.html)\n\n## Using specific components\n\n### Access raw data\n\nALIBY's tooling can also be used as an interface to OMERO servers, for example, to fetch a brightfield channel.\n ```python\nfrom aliby.io.omero import Dataset, Image\n\nserver_info= {\n            \"host\": \"host_address\",\n            \"username\": \"user\",\n            \"password\": \"xxxxxx\"}\nexpt_id = XXXX\ntps = [0, 1] # Subset of positions to get.\n\nwith Dataset(expt_id, **server_info) as conn:\n    image_ids = conn.get_images()\n\n#To get the first position\nwith Image(list(image_ids.values())[0], **server_info) as image:\n    dimg = image.data\n    imgs = dimg[tps, image.metadata[\"channels\"].index(\"Brightfield\"), 2, ...].compute()\n    # tps timepoints, Brightfield channel, z=2, all x,y\n```\n\n### Tiling the raw data\n\nA `Tiler` object performs trap registration. It may be built in different ways but the simplest one is using an image and a the default parameters set.\n\n```python\nfrom aliby.tile.tiler import Tiler, TilerParameters\nwith Image(list(image_ids.values())[0], **server_info) as image:\n    tiler = Tiler.from_image(image, TilerParameters.default())\n    tiler.run_tp(0)\n```\n\nThe initialisation should take a few seconds, as it needs to align the images\nin time.\n\nIt fetches the metadata from the Image object, and uses the TilerParameters values (all Processes in aliby depend on an associated Parameters class, which is in essence a dictionary turned into a class.)\n\n#### Get a timelapse for a given tile (remote connection)\n```python\nfpath = \"h5/location\"\n\ntile_id = 9\ntrange = range(0, 10)\nncols = 8\n\nriv = remoteImageViewer(fpath)\ntrap_tps = [riv.tiler.get_tiles_timepoint(tile_id, t) for t in trange] \n\n# You can also access labelled traps\nm_ts = riv.get_labelled_trap(tile_id=0, tps=[0])\n\n# And plot them directly\nriv.plot_labelled_trap(trap_id=0, channels=[0, 1, 2, 3], trange=range(10))\n```\n\nDepending on the network speed can take several seconds at the moment.\nFor a speed-up: take fewer z-positions if you can.\n\n#### Get the tiles for a given time point\nAlternatively, if you want to get all the traps at a given timepoint:\n\n```python\ntimepoint = (4,6)\ntiler.get_tiles_timepoint(timepoint, channels=None,\n                                z=[0,1,2,3,4])\n```\n\n\n### Contributing\nSee [CONTRIBUTING](https://aliby.readthedocs.io/en/latest/INSTALL.html) on how to help out or get involved.\n",
    "bugtrack_url": null,
    "license": "",
    "summary": "Process and analyse live-cell imaging data",
    "version": "0.1.63",
    "project_urls": null,
    "split_keywords": [],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "13d7780f8766b91758abe14c645354e8f44e8b4b8b51ab6e8863332a58ddda67",
                "md5": "adcbac84cdf4c1f36b8cb0a0ce393736",
                "sha256": "968e26b3f9fd7d9858096aad932276303d721cf9606d01160e5dd2cb7be822fc"
            },
            "downloads": -1,
            "filename": "aliby-0.1.63-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "adcbac84cdf4c1f36b8cb0a0ce393736",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.8,<3.11",
            "size": 212552,
            "upload_time": "2023-06-28T18:03:52",
            "upload_time_iso_8601": "2023-06-28T18:03:52.171268Z",
            "url": "https://files.pythonhosted.org/packages/13/d7/780f8766b91758abe14c645354e8f44e8b4b8b51ab6e8863332a58ddda67/aliby-0.1.63-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "f5acd2198a269ac06fb61ec5664217c80f2fd5a565a51c4d558fee8b44f7508f",
                "md5": "f941279e99475408bae8650a0a7b317d",
                "sha256": "85038e56eee6ad5d83b3fbdf88de4428f636760996e2c0e35b1e5147fdeaac98"
            },
            "downloads": -1,
            "filename": "aliby-0.1.63.tar.gz",
            "has_sig": false,
            "md5_digest": "f941279e99475408bae8650a0a7b317d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.8,<3.11",
            "size": 172332,
            "upload_time": "2023-06-28T18:03:55",
            "upload_time_iso_8601": "2023-06-28T18:03:55.035108Z",
            "url": "https://files.pythonhosted.org/packages/f5/ac/d2198a269ac06fb61ec5664217c80f2fd5a565a51c4d558fee8b44f7508f/aliby-0.1.63.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-06-28 18:03:55",
    "github": false,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "lcname": "aliby"
}
        
Elapsed time: 0.12736s