A DataFrame-like container for image data

Hi all, I wrote the beginnings of a DataFrame-like container for image processing. It's an experiment for the moment, a small wrapper around a dictionary of arrays, and I'd be interested in any kind of feedback https://github.com/yotam/pictureframe https://pypi.python.org/pypi/pictureframe/0.1.0 https://github.com/yotam/pictureframe/blob/master/examples/quickstart.py I wrote this because in my work I either end up with - procedural code where I pass around lots of image-shaped arrays, or - classes that have lots of image-shaped arrays as member variables I wanted to avoid having to write repeated indexing code whenever I work on a subset, and to have some guarantees about the shape of the data. I also wanted to be able to quickly generate a scaled-down version of all my arrays and to leave the door open for higher dimensional data like vxel grids. Main differences from Pandas DataFrame - Arrays can have varying dimensions, only the first `fixed_dim` dimensions must match. So you can keep together data such as RGB, depth, label distributions, weight maps and so on. - Higher dimensional data, not just a tabular structure. Main differences from scikit-image ImageCollection and MultiImage - Slicing and indexing operate on the underlying array data rather than selecting a subset of the images. - Images are constrained to match on first dimensions. - Not constrained to image data, e.g. indexing can return a PictureFrame with fewer constrained dimensions. Any thoughts, suggestions or "aren't you just reimplementing library X?" are very welcome. This is the first time I've tried to release a package so if anything seems unusual please let me know. Thanks, Yotam

Hi Yotam, thanks to bringing your package to the list's attention! Hope you will get some comments and users. Your post made me think that it would be interesting to learn from list members about their usage patterns for image processing of multiple images. As for now, we tend to avoid having too many abstractions on top of numpy arrays in scikit-image, since one of the very nice things of the package is the super-easy API image_array_out = function(image_array_in, params). But it's very interesting to know what kind of framework people use for their image processing tasks. Cheers, Emmanuelle On Tue, Apr 28, 2015 at 12:36:33AM -0700, Yotam Doron wrote:
Hi all,
I wrote the beginnings of a DataFrame-like container for image processing. It's an experiment for the moment, a small wrapper around a dictionary of arrays, and I'd be interested in any kind of feedback
https://github.com/yotam/pictureframe/blob/master/examples/quickstart.py
I wrote this because in my work I either end up with
• procedural code where I pass around lots of image-shaped arrays, or • classes that have lots of image-shaped arrays as member variables
I wanted to avoid having to write repeated indexing code whenever I work on a subset, and to have some guarantees about the shape of the data. I also wanted to be able to quickly generate a scaled-down version of all my arrays and to leave the door open for higher dimensional data like vxel grids.
Main differences from Pandas DataFrame
• Arrays can have varying dimensions, only the first `fixed_dim` dimensions must match. So you can keep together data such as RGB, depth, label distributions, weight maps and so on. • Higher dimensional data, not just a tabular structure.
Main differences from scikit-image ImageCollection and MultiImage
• Slicing and indexing operate on the underlying array data rather than selecting a subset of the images. • Images are constrained to match on first dimensions. • Not constrained to image data, e.g. indexing can return a PictureFrame with fewer constrained dimensions.
Any thoughts, suggestions or "aren't you just reimplementing library X?" are very welcome. This is the first time I've tried to release a package so if anything seems unusual please let me know.
Thanks,
Yotam

Hi Yotam On 2015-04-28 00:36:33, Yotam Doron <doron.yotam@googlemail.com> wrote:
I wrote the beginnings of a DataFrame-like container for image processing. It's an experiment for the moment, a small wrapper around a dictionary of arrays, and I'd be interested in any kind of feedback
https://github.com/yotam/pictureframe
https://pypi.python.org/pypi/pictureframe/0.1.0
https://github.com/yotam/pictureframe/blob/master/examples/quickstart.py
This looks interesting. You should also have a chat with Stephan Hoyer, the author of X-Ray. Stéfan

Hi Stéfan, Thanks for the pointer, X-Ray does look like a very close match. I'll read up on it and get in touch with Stephan. Regards, Yotam On Tuesday, 28 April 2015 20:15:07 UTC+1, stefanv wrote:
Hi Yotam
On 2015-04-28 00:36:33, Yotam Doron <doron...@googlemail.com <javascript:>>
wrote:
I wrote the beginnings of a DataFrame-like container for image processing. It's an experiment for the moment, a small wrapper around a dictionary of arrays, and I'd be interested in any kind of feedback
https://github.com/yotam/pictureframe
https://pypi.python.org/pypi/pictureframe/0.1.0
https://github.com/yotam/pictureframe/blob/master/examples/quickstart.py
This looks interesting. You should also have a chat with Stephan Hoyer, the author of X-Ray.
Stéfan
participants (3)
-
Emmanuelle Gouillart
-
Stefan van der Walt
-
Yotam Doron