spacetx / slicedimage Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
Similar to spacetx/sptx-format#22, "tests" shows up as a top-level entity in site-packages.
$ pip uninstall slicedimage
Uninstalling slicedimage-0.0.6:
Would remove:
/lifesci/groups/jrs/jamoore/miniconda2/envs/starfish/bin/slicedimage
/lifesci/groups/jrs/jamoore/miniconda2/envs/starfish/lib/python3.6/site-packages/slicedimage-0.0.6.dist-info/*
/lifesci/groups/jrs/jamoore/miniconda2/envs/starfish/lib/python3.6/site-packages/slicedimage/*
/lifesci/groups/jrs/jamoore/miniconda2/envs/starfish/lib/python3.6/site-packages/tests/*
sptx-format should move into starfish.
from an offline chat... here's a set of nouns to explain the basic concepts underlying the data structure here
A collection of images is specified by a JSON file. A collection consists of multiple tilesets, each of which is also specified by a JSON file. A tileset consists of multiple tiles.
|- collection (collection.json)
|- tileset (tileset1.json)
|- tile
|- tile
|- tile
|- tileset (tileset2.json)
|- tile
|- tileset (tileset3.json)
|- tile
|- tile
A collection is an experiment / hybridization, for each experiment we have multiple fields of view, for each field of view we have multiple tiles.
|- hybridization.json
|- hybridization_fov_000.json
|- image0.tif
|- image1.tif
|- ...
|- hybridization_fov_001.json
|- image0.tif
|- image1.tif
|- ...
The BICCN is storing image data at the Brain Image Library and BIL's current approaches for raw image data access are
An anonymous FTP backend for slicedimage
would allow users to load published BIL data locally and some authenticated method would allow the same kind of access for unpublished data on BIL.
@ttung per our slack conversation and @ambrosejcarr just in case you're interested
I was trying to use these to crop and found it difficult to understand what was going on without reading all the source code.
Additional point of confusion: it would be awesome if TileSet
(via delegation to Tile
, perhaps) could have a read
and write
methods, instead of going through an external Reader
class.
Ideally I'd like to be able to read the TileSet
, manipulate it, and then dump it to disk. I struggled to accomplish this without writing janky new code.
Do it after #29 lands
For example, in the following file structure:
experiment.json
fov_001/
hybridization.json/
file_0.tiff
The file path to file_0.tiff
in hybridization.json
needs to be fov_001/file_0.tiff
not file_0.tiff
, which is counter-intuitive.
The below code reproduces this issue -- it loads, but contains the odd file paths suggested above.
experiment = Experiment()
experiment.read('http://czi.starfish.data.public.s3.amazonaws.com/20180813/MERFISH/experiment.json')
Caveat emptor: I might be doing something wrong with ImageStack.
I'm cutting out some pieces of ImageStacks to produce smaller testing data. As far as I can tell, the only way to subset the ImageStack (e.g. as one might when cropping) is to access the private variable. If you then write to disk, it appears to write the old, uncropped data.
... which I guess makes sense, as this is a private variable, but it would be nice if this had cropping support.
A runtime check for the 2d image size would fix this, but I leave open the general problem (also relevant for starfish
of how to deal with change sizes throughout processing. As it stands, ImageStack is acting strangely read-only.
When we figure out our dependency structure, we should include in a CONTRIBUTING.md file the SOP for incrementing slicedimage so that starfish can depend on it.
Slicedimage needs to be able to read Numpy files.
We want to be able to check if the data has been downloaded locally before we load the imagestack. If it exists, we want to use the local copy in lieu of a web link.
slicedimage should outsource validation to sptx-formats, allowing us to keep any refactoring of spec-related changes to one place.
ACs:
Related to spacetx/starfish#917
@kevinyamauchi needs this.
I tried using starfish on a MERFISH image with Z = 4, C = 2 (4 depth planes and 2 fluorophore channels).
First I used the function write_experiment_json(), to seperate the image to 8 different images and create the relevant JSON. The JSON states the shapes corretly to be (2048, 2048).
Next, when running Stack.from_experiment_json() and pointing to experiment.json, I get the error
"ValueError: Starfish does not support tiles that are not identical in shape".
The size of tile.tile_shape is (2048, 2048), but the size of self._tile_shape (coming from slicedimage) is (8, 2048, 2048).
I'm attaching the resulted hybridisation
hybridization-fov_000.txt
JSON, and happy to supply any other needed information.
Many thanks,
Eyal.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.