Hi, I tried running scikits.image on Python 2.5 and noticed that Python 2.6 is required. (I got some errors for enhanced property decorators, which were introduced in 2.6.) I'm not arguing against this requirement, but this error made me think it'd be nice to have a list of requirements. I've added a "doc" branch with a requirements list. I don't really know the internals of the scikit, so the list is pretty rough. On a side note, I'm curious about the overlap of functionality in the opencv module and scipy.ndimage. Since scipy is already required, is there an advantage to using the duplicated functions in scikits.opencv? (Most of the functions in that module have no ndimage counterpart, but I'm curious about the ones that do.) Similarly, some of the filters provided by CellProfiler (listed as suggested code to adapt on the "How to contribute" page) have counterparts in scipy.ndimage. Cheers, -Tony
Hey Tony, Thanks for the report. Can you paste the error you are getting so I know exactly what decorator it is concering?, there may be a way to change it to work with Python 2.5 There is some overlap between scipy.ndimage and the OpenCV stuff. But realize, the OpenCV in the scikit are just wrappers for the OpenCV libraries, of which you need at least version 2.0 (there were some backwards incompatible changes made in 2.0). That said, my personal experience is that OpenCV is much faster than the routines in ndimage. I have timed the OpenCV 2D convlution at 100x - 1000x faster than ndimage. OpenCV is not a HARD requirement for the scikit. You can still install it and use everything else without having the opencv libs on your machine, but if and when you add them, the wrappers will "just work", you wont need to rebuild the scikit. Cheers! Chris On Thu, Nov 5, 2009 at 2:46 AM, Tony S Yu <tsyu80@gmail.com> wrote:
Hi,
I tried running scikits.image on Python 2.5 and noticed that Python 2.6 is required. (I got some errors for enhanced property decorators, which were introduced in 2.6.) I'm not arguing against this requirement, but this error made me think it'd be nice to have a list of requirements.
I've added a "doc" branch with a requirements list. I don't really know the internals of the scikit, so the list is pretty rough.
On a side note, I'm curious about the overlap of functionality in the opencv module and scipy.ndimage. Since scipy is already required, is there an advantage to using the duplicated functions in scikits.opencv? (Most of the functions in that module have no ndimage counterpart, but I'm curious about the ones that do.) Similarly, some of the filters provided by CellProfiler (listed as suggested code to adapt on the "How to contribute" page) have counterparts in scipy.ndimage.
Cheers, -Tony
On Nov 4, 2009, at 8:58 PM, Chris Colbert wrote:
Hey Tony,
Thanks for the report.
Can you paste the error you are getting so I know exactly what decorator it is concering?, there may be a way to change it to work with Python 2.5
The error I got came from importing the io module.
import scikits.image.io Traceback (most recent call last): File "<string>", line 1, in <module> File "/Users/Tony/python/devel/scikits.image/scikits/image/io/ __init__.py", line 15, in <module> from collection import * File "/Users/Tony/python/devel/scikits.image/scikits/image/io/
collection.py", line 157, in <module> class ImageCollection(object): File "/Users/Tony/python/devel/scikits.image/scikits/image/io/ collection.py", line 241, in ImageCollection @as_grey.setter AttributeError: 'property' object has no attribute 'setter'
This error should be easy to fix, but I thought that using Python 2.6 might be intentional; i.e. that was the intended target. I guess it's not clear which python the scikit targets---hence the requirements file :). Does the scikit target the same python version as scipy?
There is some overlap between scipy.ndimage and the OpenCV stuff. But realize, the OpenCV in the scikit are just wrappers for the OpenCV libraries, of which you need at least version 2.0 (there were some backwards incompatible changes made in 2.0). That said, my personal experience is that OpenCV is much faster than the routines in ndimage. I have timed the OpenCV 2D convlution at 100x - 1000x faster than ndimage.
This performance difference is exactly what I was curious about. Just out of curiosity, is it possible to rename the wrapped functions---the cv prefix seems redundant. (I don't actually have opencv installed; I'm just trying to cause trouble. ;)
OpenCV is not a HARD requirement for the scikit. You can still install it and use everything else without having the opencv libs on your machine, but if and when you add them, the wrappers will "just work", you wont need to rebuild the scikit.
Agreed, I have the requirements separated into required and optional. Thanks, -Tony
Cheers!
Chris
It is possible to change the name of the wrapped functions, but I don't for two reason: 1) they are the same name as the opencv functions they wrap, so If you know opencv you'll feel right at home 2) if you do from scikits.image.opencv import *, you get quite a few names into your namespace, the majority of them begin with cv or CV so the likelyhood of namespace pollution is low. Let me know if you have other questions. I will have a look at that error. Thanks! Cheers! Chris On Thu, Nov 5, 2009 at 3:56 AM, Tony S Yu <tsyu80@gmail.com> wrote:
On Nov 4, 2009, at 8:58 PM, Chris Colbert wrote:
Hey Tony,
Thanks for the report.
Can you paste the error you are getting so I know exactly what decorator it is concering?, there may be a way to change it to work with Python 2.5
The error I got came from importing the io module.
import scikits.image.io Traceback (most recent call last): File "<string>", line 1, in <module> File "/Users/Tony/python/devel/scikits.image/scikits/image/io/__init__.py", line 15, in <module> from collection import * File "/Users/Tony/python/devel/scikits.image/scikits/image/io/collection.py", line 157, in <module> class ImageCollection(object): File "/Users/Tony/python/devel/scikits.image/scikits/image/io/collection.py", line 241, in ImageCollection @as_grey.setter AttributeError: 'property' object has no attribute 'setter'
This error should be easy to fix, but I thought that using Python 2.6 might be intentional; i.e. that was the intended target. I guess it's not clear which python the scikit targets---hence the requirements file :). Does the scikit target the same python version as scipy?
There is some overlap between scipy.ndimage and the OpenCV stuff. But realize, the OpenCV in the scikit are just wrappers for the OpenCV libraries, of which you need at least version 2.0 (there were some backwards incompatible changes made in 2.0). That said, my personal experience is that OpenCV is much faster than the routines in ndimage. I have timed the OpenCV 2D convlution at 100x - 1000x faster than ndimage.
This performance difference is exactly what I was curious about. Just out of curiosity, is it possible to rename the wrapped functions---the cv prefix seems redundant. (I don't actually have opencv installed; I'm just trying to cause trouble. ;)
OpenCV is not a HARD requirement for the scikit. You can still install it and use everything else without having the opencv libs on your machine, but if and when you add them, the wrappers will "just work", you wont need to rebuild the scikit.
Agreed, I have the requirements separated into required and optional.
Thanks, -Tony
Cheers!
Chris
Hi Tony 2009/11/5 Tony S Yu <tsyu80@gmail.com>:
I tried running scikits.image on Python 2.5 and noticed that Python 2.6 is required. (I got some errors for enhanced property decorators, which were introduced in 2.6.) I'm not arguing against this requirement, but this error made me think it'd be nice to have a list of requirements.
I've added a "doc" branch with a requirements list. I don't really know the internals of the scikit, so the list is pretty rough.
Thanks, I think a list of dependencies would be good to include in the docs. The Python 2.6 dependency must have been accidental, though.
On a side note, I'm curious about the overlap of functionality in the opencv module and scipy.ndimage. Since scipy is already required, is there an advantage to using the duplicated functions in scikits.opencv? (Most of the functions in that module have no ndimage counterpart, but I'm curious about the ones that do.) Similarly, some of the filters provided by CellProfiler (listed as suggested code to adapt on the "How to contribute" page) have counterparts in scipy.ndimage.
Scipy.ndimage provides some low-level image manipulation tools, and we don't plan to rewrite those unless we have to. It does not, however, include a large variety of higher level algorithms, and we wish to provide those in this scikit. Like Chris mentioned, the OpenCV wrappers are a convenient way of exposing an existing well-known library, but it is not set as a dependency for any of the algorithms in the scikit. Regards Stéfan
participants (3)
-
Chris Colbert
-
Stéfan van der Walt
-
Tony S Yu