From jni.soma at gmail.com Wed Oct 1 01:15:55 2014 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Tue, 30 Sep 2014 22:15:55 -0700 (PDT) Subject: Problems with coordinate ranges when doing conversion from LCH to LAB to RGB In-Reply-To: <25d96c44-56dd-4560-82a0-c03093ab4be3@googlegroups.com> References: <25d96c44-56dd-4560-82a0-c03093ab4be3@googlegroups.com> Message-ID: <1412140555237.b62475a1@Nodemailer> Hey Matteo, I?m not familiar with all the different colour spaces, but from your second notebook you know that L in Lab ranges from 0-100, so I imagine it?s the same in Lch. Similarly for ab -> c. You might want to try 0-100 as your ranges. Various resources on the internet also point to that range, e.g., http://www.colourphil.co.uk/lab_lch_colour_space.shtml . In addition, I think your call to swapaxes to get lch256 in the final notebook might be incorrect. You need to put axis 0, the channels, at the end for our colour conversions to work, so it should be swapaxes(arr, 0, 2). Having said that, you are right that our documentation could be improved, at the very least linking to relevant web documents for each function. I?ll add an issue for this. I hope this helps, and thanks for reporting the issue! Juan. ? Sent from Mailbox On Wed, Oct 1, 2014 at 2:29 PM, Matteo wrote: > A while ago I wrote a post on my blog with code on how to import in Python > a colour palette in an ASCII file and convert it to a Matplotlib colormap: > mycarta.wordpress.com/2014/04/25/convert-color-palettes-to-python-matplotlib-colormaps/ > Following that post I wrote a tutorial on a geoscience magazine on how to > evaluate and compare colormaps using Python: > wiki.seg.org/wiki/How_to_evaluate_and_compare_color_maps > In the accompanying notebook I show how to convert a 256x3 RGB colormap to > a 256x256x3 RGB image, then convert it to CIELAB using scikit-image's > rgb2lab, then plot the 256x1 lightness (L) array to evaluate the colormaps > perceptually. > You can read the relevant extract of the notebook using this nbviewer link: > http://nbviewer.ipython.org/urls/dl.dropbox.com/s/54zoax2qesb71wn/evaluate_colormaps_skimage_test.ipynb?dl=0 > In that case scikit-image worked really well for me. > Now I am trying to follow up with a new tutorial and I run into problems > with the color space conversions. > You can follow what I am trying to do in this other notebook extract: > http://nbviewer.ipython.org/urls/dl.dropbox.com/s/noli66nzrlk0676/make_colormap_skimage_test.ipynb?dl=0 > The goal of this new tutorial is to show how to build colormaps from > scratch using perceptual principles. I design a color palette in LCH (polar > version of CIELAB) by keeping Chroma and Lightness fixed and interpolating > Hue around the circle, then convert to LAB, then to RGB. > As far as I know the code I wrote should work, but the result is a black > colormap. I am thinking I got wrong one or more of the ranges for the LCH > coordinates. I assumed L between (0,1), Ch between (0,1), and H between (0, > 2*pi). > Is that wrong, and if that's the case, what are the ranges? Many of them > are not stated clearly in the documentation in here: > http://scikit-image.org/docs/dev/api/skimage.color.html > Is it possible to update the documentation to clearly state all ranges for > all colour spaces. > Thanks for your help. > Matteo > -- > You received this message because you are subscribed to the Google Groups "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. -------------- next part -------------- An HTML attachment was scrubbed... URL: From matteo.niccoli at gmail.com Wed Oct 1 14:56:09 2014 From: matteo.niccoli at gmail.com (Matteo) Date: Wed, 1 Oct 2014 11:56:09 -0700 (PDT) Subject: Problems with coordinate ranges when doing conversion from LCH to LAB to RGB In-Reply-To: <1412140555237.b62475a1@Nodemailer> References: <25d96c44-56dd-4560-82a0-c03093ab4be3@googlegroups.com> <1412140555237.b62475a1@Nodemailer> Message-ID: <1f578d55-98ef-4460-a730-faaf1a777eed@googlegroups.com> Hi Juan Thanks so much for your reply. About a and b, to be honest they should be in the range -100, 100 as that's I think how they were defined by CIE. But I will check. I think you are rigth about L, though, that's clearly a slip on my part, odd since in the first notebook it is obvious that the output of L is in the range of 0-100. :) A good test would be to convert a single colour, say red, from RGB to LAB, to LCH, then back to LAB and RGB and check the values at each step. I'll try tomorrow and post my results back for your information. About the swapaxes, are you sure? In the first notebook I use *np.swapaxes(rgb_sp,1,2) *which seems to work. *In [4]:* *rgb_sp=np.array(zip(rsp, gsp ,bsp)) rgb_sp.shape # check the shape of the output array * * Out[4]:* *(256, 3, 256) * *In [5]:* *rgb_spectral=np.swapaxes(rgb_sp,1,2) rgb_spectral.shape # check the shape of the array again * * Out[5]:* *(256, 256, 3)* BUt again, I will check at home and confirm back. Having ranges clearly in the documentation would be great, thanks for that. Other than that, I think scikit-image is awesome, I'm using a number of the image morphology functions and they're great to work with. Cheers, Matteo On Tuesday, September 30, 2014 11:15:57 PM UTC-6, Juan Nunez-Iglesias wrote: > Hey Matteo, > > I?m not familiar with all the different colour spaces, but from your > second notebook you know that L in Lab ranges from 0-100, so I imagine it?s > the same in Lch. Similarly for ab -> c. You might want to try 0-100 as your > ranges. Various resources on the internet also point to that range, e.g., > http://www.colourphil.co.uk/lab_lch_colour_space.shtml . > > In addition, I think your call to swapaxes to get lch256 in the final > notebook might be incorrect. You need to put axis 0, the channels, at the > end for our colour conversions to work, so it should be swapaxes(arr, 0, 2). > > Having said that, you are right that our documentation could be improved, > at the very least linking to relevant web documents for each function. I?ll > add an issue for this. > > I hope this helps, and thanks for reporting the issue! > > Juan. > > ? > Sent from Mailbox > > > On Wed, Oct 1, 2014 at 2:29 PM, Matteo > > wrote: > >> A while ago I wrote a post on my blog with code on how to import in >> Python a colour palette in an ASCII file and convert it to a Matplotlib >> colormap: >> >> mycarta.wordpress.com/2014/04/25/convert-color-palettes-to-python-matplotlib-colormaps/ >> >> Following that post I wrote a tutorial on a geoscience magazine on how to >> evaluate and compare colormaps using Python: >> wiki.seg.org/wiki/How_to_evaluate_and_compare_color_maps >> >> In the accompanying notebook I show how to convert a 256x3 RGB colormap >> to a 256x256x3 RGB image, then convert it to CIELAB using scikit-image's >> rgb2lab, then plot the 256x1 lightness (L) array to evaluate the colormaps >> perceptually. >> You can read the relevant extract of the notebook using this nbviewer >> link: >> >> http://nbviewer.ipython.org/urls/dl.dropbox.com/s/54zoax2qesb71wn/evaluate_colormaps_skimage_test.ipynb?dl=0 >> In that case scikit-image worked really well for me. >> >> Now I am trying to follow up with a new tutorial and I run into problems >> with the color space conversions. >> You can follow what I am trying to do in this other notebook extract: >> >> http://nbviewer.ipython.org/urls/dl.dropbox.com/s/noli66nzrlk0676/make_colormap_skimage_test.ipynb?dl=0 >> >> The goal of this new tutorial is to show how to build colormaps from >> scratch using perceptual principles. I design a color palette in LCH (polar >> version of CIELAB) by keeping Chroma and Lightness fixed and interpolating >> Hue around the circle, then convert to LAB, then to RGB. >> As far as I know the code I wrote should work, but the result is a black >> colormap. I am thinking I got wrong one or more of the ranges for the LCH >> coordinates. I assumed L between (0,1), Ch between (0,1), and H between (0, >> 2*pi). >> Is that wrong, and if that's the case, what are the ranges? Many of them >> are not stated clearly in the documentation in here: >> http://scikit-image.org/docs/dev/api/skimage.color.html >> >> Is it possible to update the documentation to clearly state all ranges >> for all colour spaces. >> >> >> Thanks for your help. >> Matteo >> >> -- >> You received this message because you are subscribed to the Google Groups >> "scikit-image" group. >> To unsubscribe from this group and stop receiving emails from it, send an >> email to scikit-image... at googlegroups.com . >> For more options, visit https://groups.google.com/d/optout. >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From beautyofwait at gmail.com Thu Oct 2 06:46:10 2014 From: beautyofwait at gmail.com (=?UTF-8?B?67CV7IiY7KeE?=) Date: Thu, 2 Oct 2014 03:46:10 -0700 (PDT) Subject: =?UTF-8?Q?scikit=E2=80=91image=E2=80=910.10.1.win32=E2=80=91py2.7.e?= =?UTF-8?Q?xe_=EB=A1=9C_=EB=AA=A8=EB=93=88=EC=9D=84?= =?UTF-8?Q?_=EC=84=A4=EC=B9=98=ED=95=98=EC=98=80=EB=8A=94=EB=8D=B0.?= =?UTF-8?Q?_dll_error_=EA=B0=80_=EB=9C=B9=EB=8B=88=EB=8B=A4.?= Message-ID: <835fc772-987b-43ef-9571-5440896fc409@googlegroups.com> >>> from skimage import data Traceback (most recent call last): File "", line 1, in from skimage import data File "C:\Python27\lib\site-packages\skimage\data\__init__.py", line 11, in from ..io import imread File "C:\Python27\lib\site-packages\skimage\io\__init__.py", line 11, in from ._io import * File "C:\Python27\lib\site-packages\skimage\io\_io.py", line 7, in from skimage.color import rgb2grey File "C:\Python27\lib\site-packages\skimage\color\__init__.py", line 1, in from .colorconv import (convert_colorspace, File "C:\Python27\lib\site-packages\skimage\color\colorconv.py", line 57, in from scipy import linalg File "C:\Python27\lib\site-packages\scipy\linalg\__init__.py", line 159, in from .misc import * File "C:\Python27\lib\site-packages\scipy\linalg\misc.py", line 5, in from . import blas File "C:\Python27\lib\site-packages\scipy\linalg\blas.py", line 145, in from scipy.linalg import _fblas ImportError: DLL load failed: ??? ??? ?? ? ????. ? ?? ??? ???. ??? ?? ???? -------------- next part -------------- An HTML attachment was scrubbed... URL: From malonge11 at gmail.com Thu Oct 2 13:17:57 2014 From: malonge11 at gmail.com (Michael Alonge) Date: Thu, 2 Oct 2014 10:17:57 -0700 (PDT) Subject: Memory Error When Converting to LAB Color Space. Message-ID: Hello, This is my first post in this forum. Thank you in advance for any and all help. I have an image that when initially loaded in RGB yields a memory error when converted to LAB via color.rgb2lab(image). I get the following error: >>> lab_image = color.rgb2lab(image) Traceback (most recent call last): File "", line 1, in lab_image = color.rgb2lab(image) File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line 801, in rgb2lab return xyz2lab(rgb2xyz(rgb)) File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line 523, in rgb2xyz arr = _prepare_colorarray(rgb).copy() MemoryError The picture itself has the following specs: File Type: .PNG File size: 20 MB Resolution: 72 ppi image.shape = (5184, 3456, 3) I am working on a windows 7 machine with python 3.3.4. I am an intermediate python programmer, and have no idea where to start when it comes to memory allocation. Any and all help is appreciated, Thank you, Michael Alonge -------------- next part -------------- An HTML attachment was scrubbed... URL: From malonge11 at gmail.com Thu Oct 2 19:52:10 2014 From: malonge11 at gmail.com (Michael Alonge) Date: Thu, 2 Oct 2014 16:52:10 -0700 (PDT) Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: Message-ID: <461975d3-615b-45f3-9b58-deddf6dffcc8@googlegroups.com> It looks like it worked. I got the following output: Allocating # 0 Allocating # 1 Allocating # 2 Allocating # 3 Allocating # 4 Thank you, Mike Alonge On Thursday, October 2, 2014 3:50:17 PM UTC-7, Stefan van der Walt wrote: > > Hi Michael > > On Thu, Oct 2, 2014 at 7:17 PM, Michael Alonge > wrote: > > I have an image that when initially loaded in RGB yields a memory error > when > > converted to LAB via color.rgb2lab(image). I get the following error: > > Just as a basic memory size check, can you please let me know whether > the following script executes successfully? > > import numpy as np > shape = (5184, 3456, 3) > > out = [] > for i in range(5): > print("Allocating #", i) > out.append(np.zeros(shape, dtype=float).fill(1)) > > > Thanks > St?fan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Thu Oct 2 18:02:48 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Fri, 03 Oct 2014 00:02:48 +0200 Subject: Problems with coordinate ranges when doing conversion from LCH to LAB to RGB In-Reply-To: <1f578d55-98ef-4460-a730-faaf1a777eed@googlegroups.com> References: <25d96c44-56dd-4560-82a0-c03093ab4be3@googlegroups.com> <1412140555237.b62475a1@Nodemailer> <1f578d55-98ef-4460-a730-faaf1a777eed@googlegroups.com> Message-ID: <87sij6ruyf.fsf@sun.ac.za> Hi Matteo On 2014-10-01 20:56:09, Matteo wrote: > A good test would be to convert a single colour, say red, from RGB to LAB, > to LCH, then back to LAB and RGB and check the values at each step. I'll > try tomorrow and post my results back for your information. Did you have any luck with that? Also, if you come up with any good test cases that point out deficiencies in the code, we'd be happy to include them in the test suite. Thanks for the link to the article--it's very enjoyable to learn more about color map perception in such a vividly illustrated way. Regards St?fan From stefan at sun.ac.za Thu Oct 2 18:49:56 2014 From: stefan at sun.ac.za (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Fri, 3 Oct 2014 00:49:56 +0200 Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: Message-ID: Hi Michael On Thu, Oct 2, 2014 at 7:17 PM, Michael Alonge wrote: > I have an image that when initially loaded in RGB yields a memory error when > converted to LAB via color.rgb2lab(image). I get the following error: Just as a basic memory size check, can you please let me know whether the following script executes successfully? import numpy as np shape = (5184, 3456, 3) out = [] for i in range(5): print("Allocating #", i) out.append(np.zeros(shape, dtype=float).fill(1)) Thanks St?fan From matteo.niccoli at gmail.com Fri Oct 3 10:13:54 2014 From: matteo.niccoli at gmail.com (Matteo) Date: Fri, 3 Oct 2014 07:13:54 -0700 (PDT) Subject: Problems with coordinate ranges when doing conversion from LCH to LAB to RGB In-Reply-To: <87sij6ruyf.fsf@sun.ac.za> References: <25d96c44-56dd-4560-82a0-c03093ab4be3@googlegroups.com> <1412140555237.b62475a1@Nodemailer> <1f578d55-98ef-4460-a730-faaf1a777eed@googlegroups.com> <87sij6ruyf.fsf@sun.ac.za> Message-ID: Hi Stefan (and Juan) I run this test last night. Nothing fancy, essentially I created a 16x16x3 RGB azure image (RGB 0,153,255 or 0,0.6,1) and took it for a walk from RGB to LAB to LCH then back to LAB and RGB again. http://nbviewer.ipython.org/urls/dl.dropbox.com/s/44b9udiqz4npp0b/color_space_conversion_skimage.ipynb?dl=0 Feel free to use this if you like as an example of color conversion. I will be adding it to my GitHub anyway https://github.com/mycarta As you can see the loop of transformations closes precisely. When I tried with pure red (RGB 1,0,0 or 255,0,0) the final RGB values are all e-16 numbers, some negative. Not sure if that qualifies as deficiencies. Certainly it points to me to the need to include documenntation on the coordinate ranges as Juan observed. >From this I conclude that: r,g, and b are in the range (0 1) L is in the range (0 100) as Juan pointed out (already evident from my color evaluation notebook), however a and b must be in the range (-100 100) since a is small but positive and b is large but negative (as expected) in my example chrima c must be in the range (0 100) because it is the distance from the polar axis so it can't be negative h is in the range (0 2pi) as specified already in the documentation I hope this is useful. I'l lbe checking my original example with the new ranges tonigth. Cheers Matteo On Thursday, October 2, 2014 4:02:54 PM UTC-6, Stefan van der Walt wrote: > Hi Matteo > > On 2014-10-01 20:56:09, Matteo > > wrote: > > A good test would be to convert a single colour, say red, from RGB to > LAB, > > to LCH, then back to LAB and RGB and check the values at each step. I'll > > try tomorrow and post my results back for your information. > > Did you have any luck with that? Also, if you come up with any good > test cases that point out deficiencies in the code, we'd be happy to > include them in the test suite. > > Thanks for the link to the article--it's very enjoyable to learn more > about color map perception in such a vividly illustrated way. > > Regards > St?fan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Fri Oct 3 04:37:30 2014 From: stefan at sun.ac.za (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Fri, 3 Oct 2014 10:37:30 +0200 Subject: =?UTF-8?B?UmU6IHNjaWtpdOKAkWltYWdl4oCRMC4xMC4xLndpbjMy4oCRcHkyLjcuZXhlIOuhnCA=?= =?UTF-8?B?66qo65OI7J2EIOyEpOy5mO2VmOyYgOuKlOuNsC4gZGxsIGVycm9yIOqwgCDrnLnri4jri6Qu?= In-Reply-To: <835fc772-987b-43ef-9571-5440896fc409@googlegroups.com> References: <835fc772-987b-43ef-9571-5440896fc409@googlegroups.com> Message-ID: On Oct 3, 2014 8:09 AM, "???" wrote: > > >>> from skimage import data > > Traceback (most recent call last): > File "", line 1, in > from skimage import data > File "C:\Python27\lib\site-packages\skimage\data\__init__.py", line 11, in > from ..io import imread > File "C:\Python27\lib\site-packages\skimage\io\__init__.py", line 11, in > from ._io import * > File "C:\Python27\lib\site-packages\skimage\io\_io.py", line 7, in > from skimage.color import rgb2grey > File "C:\Python27\lib\site-packages\skimage\color\__init__.py", line 1, in > from .colorconv import (convert_colorspace, > File "C:\Python27\lib\site-packages\skimage\color\colorconv.py", line 57, in > from scipy import linalg > File "C:\Python27\lib\site-packages\scipy\linalg\__init__.py", line 159, in > from .misc import * > File "C:\Python27\lib\site-packages\scipy\linalg\misc.py", line 5, in > from . import blas > File "C:\Python27\lib\site-packages\scipy\linalg\blas.py", line 145, in > from scipy.linalg import _fblas > ImportError: DLL load failed: ??? ??? ?? ? ????. Note that this is an issue with SciPy, not scikit-image. Please follow up there. Regards St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From eldad.afik at gmail.com Mon Oct 6 03:50:27 2014 From: eldad.afik at gmail.com (Eldad Afik) Date: Mon, 6 Oct 2014 00:50:27 -0700 (PDT) Subject: robust ring (and circle) detection algorithm In-Reply-To: References: <12336b1a-85c8-4127-a459-d2e0f6a54388@googlegroups.com> Message-ID: <2a5a87da-0db8-4ff4-98cd-a4041ecb8e19@googlegroups.com> Hello, Unfortunately I never got to revising the code for a pull request, nor documenting it as I would have liked. A Cython code is available at ridge-directed-ring-detector where you can also find a usage example in the format of an ipython-notebook; a static view is available here . For those who are interested, the manuscript has been updated (version v2) and is available at arXiv:1310.1371 . In case there is interest from the community, I can try to modify it to conform to the scikit-image standards, based on your comments. Congratulations for the new scikit-image paper! Best wishes, Eldad On Thursday, 13 March 2014 23:34:32 UTC+2, Stefan van der Walt wrote: > > Hi Eldad > > On Sun, Mar 9, 2014 at 3:28 PM, Eldad Afik > wrote: > > I summarised the work in a manuscript titled: > > "Robust and highly performant ring detection algorithm for 3d particle > > tracking using 2d microscope imaging" (a pre-print is available at > > arXiv:1310.1371). > > NB, it was written minded at potential users and applications rather > than > > computer scientists, which I am not. > > Shall we start working on a pull request with a proof of concept > illustration? > > St?fan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tsyu80 at gmail.com Mon Oct 6 02:25:32 2014 From: tsyu80 at gmail.com (Tony Yu) Date: Mon, 6 Oct 2014 01:25:32 -0500 Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: <461975d3-615b-45f3-9b58-deddf6dffcc8@googlegroups.com> References: <461975d3-615b-45f3-9b58-deddf6dffcc8@googlegroups.com> Message-ID: That was more of a test of re-allocation of memory (i.e. let's make sure there's no memory leaks), but there may be issues with total available memory. Although the original image is only 20 MB, that's in its compressed state. It's a bit more than twice that as uint8 (uncompressed state). And when converted to float (which is preferable so basic math doesn't go crazy without some hand-holding), it's closer to 400 MB. Combine that with the fact that the conversion ends up copying the image due to some simple operations, and you're looking at about 1.5 GB. (I haven't actually tried verifying the memory usage, so don't quote me on that). How much memory does your system have? Also, just as a check: Are you running 64-bit python (this is displayed when you start up the python interpreter.) On Thu, Oct 2, 2014 at 6:52 PM, Michael Alonge wrote: > It looks like it worked. I got the following output: > > > Allocating # 0 > Allocating # 1 > Allocating # 2 > Allocating # 3 > Allocating # 4 > > Thank you, > > Mike Alonge > On Thursday, October 2, 2014 3:50:17 PM UTC-7, Stefan van der Walt wrote: >> >> Hi Michael >> >> On Thu, Oct 2, 2014 at 7:17 PM, Michael Alonge >> wrote: >> > I have an image that when initially loaded in RGB yields a memory error >> when >> > converted to LAB via color.rgb2lab(image). I get the following error: >> >> Just as a basic memory size check, can you please let me know whether >> the following script executes successfully? >> >> import numpy as np >> shape = (5184, 3456, 3) >> >> out = [] >> for i in range(5): >> print("Allocating #", i) >> out.append(np.zeros(shape, dtype=float).fill(1)) >> >> >> Thanks >> St?fan >> > -- > You received this message because you are subscribed to the Google Groups > "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From malonge11 at gmail.com Mon Oct 6 13:23:30 2014 From: malonge11 at gmail.com (Michael Alonge) Date: Mon, 6 Oct 2014 10:23:30 -0700 (PDT) Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: Message-ID: <4efcb58d-8eb7-4864-98d8-b6b8fef7bd09@googlegroups.com> Thanks so much for the help. I am processing with 32 GB of RAM and a 64-bit operating system. That being said, I am running the 32 bit version of python. On Thursday, October 2, 2014 10:17:57 AM UTC-7, Michael Alonge wrote: > > Hello, > > This is my first post in this forum. Thank you in advance for any and all > help. > > I have an image that when initially loaded in RGB yields a memory error > when converted to LAB via color.rgb2lab(image). I get the following error: > > >>> lab_image = color.rgb2lab(image) > Traceback (most recent call last): > File "", line 1, in > lab_image = color.rgb2lab(image) > File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line > 801, in rgb2lab > return xyz2lab(rgb2xyz(rgb)) > File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line > 523, in rgb2xyz > arr = _prepare_colorarray(rgb).copy() > MemoryError > > The picture itself has the following specs: > > File Type: .PNG > > File size: 20 MB > > Resolution: 72 ppi > > image.shape = (5184, 3456, 3) > > I am working on a windows 7 machine with python 3.3.4. > > I am an intermediate python programmer, and have no idea where to start > when it comes to memory allocation. Any and all help is appreciated, > > Thank you, > > Michael Alonge > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Mon Oct 6 06:09:51 2014 From: stefan at sun.ac.za (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Mon, 6 Oct 2014 12:09:51 +0200 Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: <461975d3-615b-45f3-9b58-deddf6dffcc8@googlegroups.com> Message-ID: On Oct 6, 2014 8:26 AM, "Tony Yu" wrote: > > That was more of a test of re-allocation of memory (i.e. let's make sure there's no memory leaks), but there may be issues with total available memory. The arrays are stored in "out", so my aim was to test total memory allocation (which seems fine). I can't imagine that we are making so many copies, but I could be wrong. Best is to run a memory profile. St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From malonge11 at gmail.com Mon Oct 6 16:40:25 2014 From: malonge11 at gmail.com (Michael Alonge) Date: Mon, 6 Oct 2014 13:40:25 -0700 (PDT) Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: Message-ID: <6dbcea38-f3fb-460b-b97a-9ed1c8d30d63@googlegroups.com> That did the trick! Thanks so much for the help everyone. On Thursday, October 2, 2014 10:17:57 AM UTC-7, Michael Alonge wrote: > > Hello, > > This is my first post in this forum. Thank you in advance for any and all > help. > > I have an image that when initially loaded in RGB yields a memory error > when converted to LAB via color.rgb2lab(image). I get the following error: > > >>> lab_image = color.rgb2lab(image) > Traceback (most recent call last): > File "", line 1, in > lab_image = color.rgb2lab(image) > File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line > 801, in rgb2lab > return xyz2lab(rgb2xyz(rgb)) > File "C:\Python33\lib\site-packages\skimage\color\colorconv.py", line > 523, in rgb2xyz > arr = _prepare_colorarray(rgb).copy() > MemoryError > > The picture itself has the following specs: > > File Type: .PNG > > File size: 20 MB > > Resolution: 72 ppi > > image.shape = (5184, 3456, 3) > > I am working on a windows 7 machine with python 3.3.4. > > I am an intermediate python programmer, and have no idea where to start > when it comes to memory allocation. Any and all help is appreciated, > > Thank you, > > Michael Alonge > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsch at demuc.de Mon Oct 6 15:53:57 2014 From: jsch at demuc.de (=?windows-1252?Q?Johannes_Sch=0F=F6nberger?=) Date: Mon, 6 Oct 2014 15:53:57 -0400 Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: References: <4efcb58d-8eb7-4864-98d8-b6b8fef7bd09@googlegroups.com> Message-ID: <69BC3AA6-09EE-422A-B5E3-ABAB37FD2D7B@demuc.de> > With that version of Python, you cannot access even a fraction of that memory. He should be able to access a ?fraction" of the memory, though ;-) Johannes Sch?nberger On Oct 6, 2014, at 3:50 PM, St?fan van der Walt wrote: > On Oct 6, 2014 8:28 PM, "Michael Alonge" wrote: > > > > Thanks so much for the help. > > > > I am processing with 32 GB of RAM and a 64-bit operating system. That being said, I am running the 32 bit version of python. > > With that version of Python, you cannot access even a fraction of that memory. Can you try the 64-bit version? > > St?fan > > > -- > You received this message because you are subscribed to the Google Groups "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. From stefan at sun.ac.za Mon Oct 6 15:50:22 2014 From: stefan at sun.ac.za (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Mon, 6 Oct 2014 21:50:22 +0200 Subject: Memory Error When Converting to LAB Color Space. In-Reply-To: <4efcb58d-8eb7-4864-98d8-b6b8fef7bd09@googlegroups.com> References: <4efcb58d-8eb7-4864-98d8-b6b8fef7bd09@googlegroups.com> Message-ID: On Oct 6, 2014 8:28 PM, "Michael Alonge" wrote: > > Thanks so much for the help. > > I am processing with 32 GB of RAM and a 64-bit operating system. That being said, I am running the 32 bit version of python. With that version of Python, you cannot access even a fraction of that memory. Can you try the 64-bit version? St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From pratapgr8 at gmail.com Tue Oct 7 05:24:47 2014 From: pratapgr8 at gmail.com (Pratap Vardhan) Date: Tue, 7 Oct 2014 02:24:47 -0700 (PDT) Subject: ellipse-shaped structuring element for morphology Message-ID: <609b6184-df6b-4485-a952-a2f7792f81c5@googlegroups.com> Here's a ellipse-shaped structuring element for morphology operations In [131]: def ellipse(w, h, dtype=np.uint8): """ Generates a flat, ellipse-shaped structuring element. Parameters ---------- w : int The width of ellipse h : int The height of ellipse Other Parameters ---------------- dtype : data-type The data type of the structuring element. Returns ------- selem : ndarray A structuring element consisting only of ones, i.e. every pixel belongs to the neighborhood. """ X, Y = np.meshgrid(range(-w, w + 1), range(-h, h + 1)) return np.array(((h*X) ** 2 + (w*Y) ** 2) <= (w*h) ** 2, dtype=np.uint8) In [129]: ellipse(3, 3) Out[129]: array([[0, 0, 0, 1, 0, 0, 0], [0, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 1, 1, 0], [1, 1, 1, 1, 1, 1, 1], [0, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 1, 1, 0], [0, 0, 0, 1, 0, 0, 0]], dtype=uint8) In [130]: ellipse(5, 3) Out[130]: array([[0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0]], dtype=uint8) Can this be taken as it is or certain approximation formulas need to be used? Any alternative way skimage uses as of now? If not, can this go as a PR? -------------- next part -------------- An HTML attachment was scrubbed... URL: From pratapgr8 at gmail.com Tue Oct 7 05:48:30 2014 From: pratapgr8 at gmail.com (Pratap Vardhan) Date: Tue, 7 Oct 2014 02:48:30 -0700 (PDT) Subject: ellipse-shaped structuring element for morphology In-Reply-To: <609b6184-df6b-4485-a952-a2f7792f81c5@googlegroups.com> References: <609b6184-df6b-4485-a952-a2f7792f81c5@googlegroups.com> Message-ID: Updating with plain text def ellipse(w, h, dtype=np.uint8): """ Generates a flat, ellipse-shaped structuring element. Parameters ---------- w : int The width of ellipse h : int The height of ellipse Other Parameters ---------------- dtype : data-type The data type of the structuring element. Returns ------- selem : ndarray A structuring element consisting only of ones, i.e. every pixel belongs to the neighborhood. """ X, Y = np.meshgrid(range(-w, w + 1), range(-h, h + 1)) return np.array(((h*X) ** 2 + (w*Y) ** 2) <= (w*h) ** 2, dtype=np.uint8) ellipse(3, 3) array([[0, 0, 0, 1, 0, 0, 0], [0, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 1, 1, 0], [1, 1, 1, 1, 1, 1, 1], [0, 1, 1, 1, 1, 1, 0], [0, 1, 1, 1, 1, 1, 0], [0, 0, 0, 1, 0, 0, 0]], dtype=uint8) ellipse(3, 5) array([[0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0], [0, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0], [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0]], dtype=uint8) On Tuesday, October 7, 2014 2:54:48 PM UTC+5:30, Pratap Vardhan wrote: > > Here's a ellipse-shaped structuring element for morphology operations > > Can this be taken as it is or certain approximation formulas need to be > used? Any alternative way skimage uses as of now? If not, can this go as a > PR? > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Tue Oct 7 05:54:00 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Tue, 07 Oct 2014 11:54:00 +0200 Subject: ellipse-shaped structuring element for morphology In-Reply-To: <609b6184-df6b-4485-a952-a2f7792f81c5@googlegroups.com> References: <609b6184-df6b-4485-a952-a2f7792f81c5@googlegroups.com> Message-ID: <87mw985hon.fsf@sun.ac.za> Hi Pratap On 2014-10-07 11:24:47, Pratap Vardhan wrote: > Here's a ellipse-shaped structuring element for morphology operations Having such an element would be neat. Can you re-use the ellipse-drawing functionality from skimage.draw to avoid code duplication? St?fan From kmichael.aye at gmail.com Wed Oct 8 20:55:54 2014 From: kmichael.aye at gmail.com (Michael Aye) Date: Wed, 8 Oct 2014 17:55:54 -0700 (PDT) Subject: some broken links in example notebooks Message-ID: <03cb4e22-e4b9-48fe-990b-e3a1e033efd6@googlegroups.com> I guess you create the example notebooks somehow automatically with sphinx? Because the descriptive text is written in html which mostly shows up well in the notebook, but the links to other skimage functions do show up weird/broken. I even don't know if it's possible or reasonable to fix that somehow for a locally downloaded notebook, but I just wanted to inform you in case you were not aware. My example is for http://scikit-image.org/docs/dev/auto_examples/plot_blob.html The way it's shown in my notebook (ipython 2.3) can be seen here: https://www.dropbox.com/s/ptzoqfx22yhn5vu/Screenshot%202014-10-08%2017.54.48.pdf?dl=0 If you think it's worth a GH issue, just say the word and I create one. Regards, Michael -------------- next part -------------- An HTML attachment was scrubbed... URL: From malonge11 at gmail.com Thu Oct 9 14:48:29 2014 From: malonge11 at gmail.com (Michael Alonge) Date: Thu, 9 Oct 2014 11:48:29 -0700 (PDT) Subject: RGB Value Confusion Message-ID: <7028d561-74c3-4f88-8d13-4cc457552e1b@googlegroups.com> Hello, Maybe this is quite trivial, but I am a little confused about the RGB values represented in my numpy arrays. I get floats between zero and one, such as (0.45803295125156029, 0.10643323197708233, 0.18076931323028619) (this should be a slightly red color). Is there a way for me to convert this to normal RGB values? My understanding is that they should be whole integers. Thank you, Michael Alonge -------------- next part -------------- An HTML attachment was scrubbed... URL: From pratapgr8 at gmail.com Thu Oct 9 15:06:32 2014 From: pratapgr8 at gmail.com (Pratap Vardhan) Date: Thu, 9 Oct 2014 12:06:32 -0700 (PDT) Subject: RGB Value Confusion In-Reply-To: <7028d561-74c3-4f88-8d13-4cc457552e1b@googlegroups.com> References: <7028d561-74c3-4f88-8d13-4cc457552e1b@googlegroups.com> Message-ID: You could convert data like skimage.img_as_ubyte(floatdata) Read more about data types here http://scikit-image.org/docs/dev/user_guide/data_types.html Thanks, Pratap On Friday, October 10, 2014 12:18:30 AM UTC+5:30, Michael Alonge wrote: > > Hello, > > Maybe this is quite trivial, but I am a little confused about the RGB > values represented in my numpy arrays. > > I get floats between zero and one, such as (0.45803295125156029, > 0.10643323197708233, 0.18076931323028619) (this should be a slightly red > color). > > Is there a way for me to convert this to normal RGB values? My > understanding is that they should be whole integers. > > Thank you, > > Michael Alonge > -------------- next part -------------- An HTML attachment was scrubbed... URL: From steven.silvester at gmail.com Sat Oct 11 16:04:57 2014 From: steven.silvester at gmail.com (Steven Silvester) Date: Sat, 11 Oct 2014 13:04:57 -0700 (PDT) Subject: Handy Bash Function for Creating Branches Message-ID: <485d1e45-17f7-4032-8b01-eefa96b40f40@googlegroups.com> Hi all, I added the following to my .bashrc for creating new branches: function gn() { git checkout -b "$1" upstream/master } I use it as follows: $ gn temp2 Branch temp2 set up to track remote branch master from upstream. Switched to a new branch 'temp2' This saves me from forgetting to branch against upstream master all the time. Regards, Steve ? -------------- next part -------------- An HTML attachment was scrubbed... URL: From tcaswell at gmail.com Sat Oct 11 18:26:20 2014 From: tcaswell at gmail.com (Thomas Caswell) Date: Sat, 11 Oct 2014 18:26:20 -0400 Subject: Handy Bash Function for Creating Branches In-Reply-To: <87r3yejlg8.fsf@sun.ac.za> References: <485d1e45-17f7-4032-8b01-eefa96b40f40@googlegroups.com> <87r3yejlg8.fsf@sun.ac.za> Message-ID: hub from the github folks (https://github.com/github/hub) also automates a bunch of stuff like adding remotes/cloning from gh. Tom On Sat, Oct 11, 2014 at 6:22 PM, Stefan van der Walt wrote: > On 2014-10-11 22:04:57, Steven Silvester wrote: >> Hi all, >> >> I added the following to my .bashrc for creating new branches: >> >> function gn() { >> git checkout -b "$1" upstream/master >> } > > Since we're on the topic: > > https://gist.github.com/stefanv/e9135cc899deda1141b0 > > git-nr xyz -- Create a new remote for GitHub user xyz > git-pr 100 -- Check out pr #100 into branch pr/100 > git-wipe filename -- Remove filename from the repo entirely > > St?fan > > -- > You received this message because you are subscribed to the Google Groups "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. -- Thomas Caswell tcaswell at gmail.com From stefan at sun.ac.za Sat Oct 11 18:22:31 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Sun, 12 Oct 2014 00:22:31 +0200 Subject: Handy Bash Function for Creating Branches In-Reply-To: <485d1e45-17f7-4032-8b01-eefa96b40f40@googlegroups.com> References: <485d1e45-17f7-4032-8b01-eefa96b40f40@googlegroups.com> Message-ID: <87r3yejlg8.fsf@sun.ac.za> On 2014-10-11 22:04:57, Steven Silvester wrote: > Hi all, > > I added the following to my .bashrc for creating new branches: > > function gn() { > git checkout -b "$1" upstream/master > } Since we're on the topic: https://gist.github.com/stefanv/e9135cc899deda1141b0 git-nr xyz -- Create a new remote for GitHub user xyz git-pr 100 -- Check out pr #100 into branch pr/100 git-wipe filename -- Remove filename from the repo entirely St?fan From jim at rybarski.com Sun Oct 12 11:09:09 2014 From: jim at rybarski.com (jim at rybarski.com) Date: Sun, 12 Oct 2014 08:09:09 -0700 (PDT) Subject: MultiImage, converse_memory and tifffile plugin Message-ID: <2b83bd54-d229-439d-97da-90e66dcaaeac@googlegroups.com> So recently I had to stop using MultiImage to open up a large TIFF stack as I kept getting memory errors, even when using converse_memory=True (it ends up loading the entire file into memory regardless). I installed the tifffile module and used that instead, as it has the ability to open the file but load only one image at a time. I think it would be nice if MultiImage was able to do this automatically (or by getting a plugin argument), especially since the behavior of the TiffFile class is conceptually very similar to MultiImage. Thoughts? -------------- next part -------------- An HTML attachment was scrubbed... URL: From steven.silvester at gmail.com Sun Oct 12 19:45:46 2014 From: steven.silvester at gmail.com (Steven Silvester) Date: Sun, 12 Oct 2014 16:45:46 -0700 (PDT) Subject: MultiImage, converse_memory and tifffile plugin In-Reply-To: <2b83bd54-d229-439d-97da-90e66dcaaeac@googlegroups.com> References: <2b83bd54-d229-439d-97da-90e66dcaaeac@googlegroups.com> Message-ID: Sounds reasonable, I'm going to open a PR to handle TIFF files with `tifffile` in `MultiImage`. On Sunday, October 12, 2014 10:09:09 AM UTC-5, j... at rybarski.com wrote: > > So recently I had to stop using MultiImage to open up a large TIFF stack > as I kept getting memory errors, even when using converse_memory=True (it > ends up loading the entire file into memory regardless). I installed the > tifffile module and used that instead, as it has the ability to open the > file but load only one image at a time. > > I think it would be nice if MultiImage was able to do this automatically > (or by getting a plugin argument), especially since the behavior of the > TiffFile class is conceptually very similar to MultiImage. Thoughts? > > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From georgeshattab at gmail.com Mon Oct 13 05:49:05 2014 From: georgeshattab at gmail.com (Georges H) Date: Mon, 13 Oct 2014 02:49:05 -0700 (PDT) Subject: Build error Message-ID: <12a83237-5610-416e-b871-2a123f39d25c@googlegroups.com> Hi all, I'm encountering a problem with the installation from source for scikit-image-master sudo python setup.py install Output is : creating build/temp.macosx-10.9-intel-2.7 compile options: '-I/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c' cc: geometry.c clang: error: no such file or directory: 'geometry.c' clang: error: no input files clang: error: no such file or directory: 'geometry.c' clang: error: no input files error: Command "cc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 -arch i386 -g -Os -pipe -fno-common -fno-strict-aliasing -fwrapv -DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-prototypes -Wshorten-64-to-32 -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes -DENABLE_DTRACE -arch x86_64 -arch i386 -pipe -I/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 -c geometry.c -o build/temp.macosx-10.9-intel-2.7/geometry.o" failed with exit status 1 All requirements are installed and running under osx I also did a clean : clean sudo python setup.py clean --all and retried same result any insight is greatly appreciated. Thanks. -------------- next part -------------- An HTML attachment was scrubbed... URL: From georgeshattab at gmail.com Mon Oct 13 09:02:11 2014 From: georgeshattab at gmail.com (Georges H) Date: Mon, 13 Oct 2014 06:02:11 -0700 (PDT) Subject: Build error In-Reply-To: <12a83237-5610-416e-b871-2a123f39d25c@googlegroups.com> References: <12a83237-5610-416e-b871-2a123f39d25c@googlegroups.com> Message-ID: <4129cd97-ae16-4241-860e-7cbcfd69eead@googlegroups.com> Bypassed this problem using the ScipySuperpack Keeping this since it may be helpful to someone cheers On Monday, 13 October 2014 11:49:06 UTC+2, Georges H wrote: > > Hi all, > > I'm encountering a problem with the installation from source for > scikit-image-master > > > sudo python setup.py install > > > Output is : > > > creating build/temp.macosx-10.9-intel-2.7 > > compile options: > '-I/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include > -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 > -c' > > cc: geometry.c > > clang: error: no such file or directory: 'geometry.c' > > clang: error: no input files > > clang: error: no such file or directory: 'geometry.c' > > clang: error: no input files > > error: Command "cc -fno-strict-aliasing -fno-common -dynamic -arch x86_64 > -arch i386 -g -Os -pipe -fno-common -fno-strict-aliasing -fwrapv > -DENABLE_DTRACE -DMACOSX -DNDEBUG -Wall -Wstrict-prototypes > -Wshorten-64-to-32 -DNDEBUG -g -fwrapv -Os -Wall -Wstrict-prototypes > -DENABLE_DTRACE -arch x86_64 -arch i386 -pipe > -I/System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python/numpy/core/include > -I/System/Library/Frameworks/Python.framework/Versions/2.7/include/python2.7 > -c geometry.c -o build/temp.macosx-10.9-intel-2.7/geometry.o" failed with > exit status 1 > > > All requirements are installed and running under osx > > I also did a clean : > > > clean sudo python setup.py clean --all > > > and retried same result > any insight is greatly appreciated. Thanks. > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Mon Oct 13 18:47:16 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Tue, 14 Oct 2014 00:47:16 +0200 Subject: Build error In-Reply-To: <4129cd97-ae16-4241-860e-7cbcfd69eead@googlegroups.com> References: <12a83237-5610-416e-b871-2a123f39d25c@googlegroups.com> <4129cd97-ae16-4241-860e-7cbcfd69eead@googlegroups.com> Message-ID: <87ppdvvb7v.fsf@sun.ac.za> On 2014-10-13 15:02:11, Georges H wrote: > Bypassed this problem using the ScipySuperpack > > Keeping this since it may be helpful to someone Strange, I wonder what went wrong. Glad you found a solution, though. St?fan From simon at simonluijk.com Wed Oct 15 10:50:40 2014 From: simon at simonluijk.com (Simon) Date: Wed, 15 Oct 2014 07:50:40 -0700 (PDT) Subject: Python book on computer vision Message-ID: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> Hi All, I am looking for a book on computer vision in python. I am relatively new to computer vision but have some experience in AI. I have learnt a fair amount form scikit-image documentation and trying things out, but need some more overview. Most of the books I have found are related to opencv. Does anyone have a book that they can recommend. I am more interested in getting an overview of the different techniques of object recognition and categorisation then code examples. Thanks Simon -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Wed Oct 15 11:23:55 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Wed, 15 Oct 2014 17:23:55 +0200 Subject: Python book on computer vision In-Reply-To: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> References: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> Message-ID: <87a94xuzjo.fsf@sun.ac.za> Hi Simon On 2014-10-15 16:50:40, Simon wrote: > I am looking for a book on computer vision in python. I am relatively new > to computer vision but have some experience in AI. I have learnt a fair > amount form scikit-image documentation and trying things out, but need some > more overview. Most of the books I have found are related to opencv. Does > anyone have a book that they can recommend. I am more interested in getting > an overview of the different techniques of object recognition and > categorisation then code examples. Have a look at Richard Szeliski from Microsoft's book: http://szeliski.org/Book/ St?fan From joschka.jacobsmuehlen at lfb.rwth-aachen.de Thu Oct 16 03:40:23 2014 From: joschka.jacobsmuehlen at lfb.rwth-aachen.de (=?UTF-8?Q?Joschka_zur_Jacobsm=C3=BChlen?=) Date: Thu, 16 Oct 2014 00:40:23 -0700 (PDT) Subject: Python book on computer vision In-Reply-To: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> References: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> Message-ID: <9b4f2656-bdfc-464d-a845-f36fc46aa2a8@googlegroups.com> Hi Simon, for an overview Stefan's recommendation is a good start. On Wednesday, October 15, 2014 4:50:40 PM UTC+2, Simon wrote: > > Hi All, > > I am looking for a book on computer vision in python. > For Python you can have a look at Jan Erik Solem's book "Computer Vision in Python" (O'Reilly): http://programmingcomputervision.com/ You can download a PDF file of the final draft and all code files from this website. Joschka -------------- next part -------------- An HTML attachment was scrubbed... URL: From agaldran at gmail.com Thu Oct 16 05:13:34 2014 From: agaldran at gmail.com (=?UTF-8?Q?Adri=C3=A1n_Galdr=C3=A1n?=) Date: Thu, 16 Oct 2014 02:13:34 -0700 (PDT) Subject: Python book on computer vision In-Reply-To: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> References: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> Message-ID: <810f1b40-ba6c-4e2d-b8f2-4739b6143720@googlegroups.com> Hi Simon, The book by Jan Enrik Solem entitled "Programming Computer Vision with Python" is freely available here: http://programmingcomputervision.com/ It comes with plenty of code (there is a github repository accompanying the book) and it has a nice learn-by-doing approach. Cheers, Adrian El mi?rcoles, 15 de octubre de 2014 16:50:40 UTC+2, Simon escribi?: > > Hi All, > > I am looking for a book on computer vision in python. I am relatively new > to computer vision but have some experience in AI. I have learnt a fair > amount form scikit-image documentation and trying things out, but need some > more overview. Most of the books I have found are related to opencv. Does > anyone have a book that they can recommend. I am more interested in getting > an overview of the different techniques of object recognition and > categorisation then code examples. > > Thanks > Simon > -------------- next part -------------- An HTML attachment was scrubbed... URL: From spagodo at gmail.com Thu Oct 16 14:54:08 2014 From: spagodo at gmail.com (Christopher) Date: Thu, 16 Oct 2014 11:54:08 -0700 (PDT) Subject: scikit-image fft Message-ID: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> Hi all, Discovered sci-image recently, and I like it so far. Right now I am basically trying to do an fft, filter out certain frequencies, and then back transform it to an image. My first thought was to use fft, but I can't find an fft function in the docs. I see that numpy has an fft function, but running that on a sci-kit image gives unpleasant errors. Is there perhaps a better method for this than fft? Any suggestions? chris -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Thu Oct 16 08:16:42 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Thu, 16 Oct 2014 14:16:42 +0200 Subject: Python book on computer vision In-Reply-To: <810f1b40-ba6c-4e2d-b8f2-4739b6143720@googlegroups.com> References: <99d26325-8ff6-4702-80e1-3f2c409f6fc7@googlegroups.com> <810f1b40-ba6c-4e2d-b8f2-4739b6143720@googlegroups.com> Message-ID: <87r3y8tdjp.fsf@sun.ac.za> On 2014-10-16 11:13:34, Adri?n Galdr?n wrote: > The book by Jan Enrik Solem entitled "Programming Computer Vision with > Python" is freely available here: > > http://programmingcomputervision.com/ I had a look at the book--it's a useful resource in the cookbook style. Note, however, that it does not make use of many of the advanced features available in scikit-learn and scikit-image, so do your homework before using those code snippets. St?fan From jni.soma at gmail.com Thu Oct 16 18:00:03 2014 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Thu, 16 Oct 2014 15:00:03 -0700 (PDT) Subject: scikit-image fft In-Reply-To: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> References: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> Message-ID: <1413496803221.5d6c120c@Nodemailer> Hi Chris, One of our main selling points is that we interop seamlessly with numpy. Doing an fft is one of those interops! Indeed it should "just work". Can you post more details about the error you're seeing? Welcome! =) Juan. On Fri, Oct 17, 2014 at 7:26 AM, Christopher wrote: > Hi all, > Discovered sci-image recently, and I like it so far. Right now I am > basically trying to do an fft, filter out certain frequencies, and then > back transform it to an image. My first thought was to use fft, but I can't > find an fft function in the docs. I see that numpy has an fft function, but > running that on a sci-kit image gives unpleasant errors. Is there perhaps a > better method for this than fft? Any suggestions? > chris > -- > You received this message because you are subscribed to the Google Groups "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. -------------- next part -------------- An HTML attachment was scrubbed... URL: From spagodo at gmail.com Thu Oct 16 19:14:59 2014 From: spagodo at gmail.com (Christopher) Date: Thu, 16 Oct 2014 16:14:59 -0700 (PDT) Subject: scikit-image fft In-Reply-To: <1413496803221.5d6c120c@Nodemailer> References: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> <1413496803221.5d6c120c@Nodemailer> Message-ID: <6958a384-d8ed-4c82-a87e-8ba4bfd7b84d@googlegroups.com> Thanks Juan for the response! It appears that the problem was that numpy fft returns a complex array, which gave an error when trying to display it. By extracting only the real parts of the array, it seems to work fine. This is a sample of what I was trying to do: import numpy from numpy import fft from skimage import io, data import matplotlib.pyplot as plot im = data.coffee() f = fft.fft2(im) f2 = fft.ifft2(f) r = numpy.real(f2) plot.imshow(r) plot.show() Thanks again -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Thu Oct 16 21:52:24 2014 From: stefan at sun.ac.za (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Fri, 17 Oct 2014 03:52:24 +0200 Subject: scikit-image fft In-Reply-To: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> References: <3c44424e-4d8f-409e-8f69-5282782dd8ea@googlegroups.com> Message-ID: Hi Chris Welcome to the list! On Oct 16, 2014 10:26 PM, "Christopher" wrote: > > Discovered sci-image recently, and I like it so far. Right now I am basically trying to do an fft, filter out certain frequencies, and then back transform it to an image. My first thought was to use fft, but I can't find an fft function in the docs. I see that numpy has an fft function, but running that on a sci-kit image gives unpleasant errors. Is there perhaps a better method for this than fft? Any suggestions? Have a look at the exercise for the FFT chapter in the scipy lecture notes: http://scipy-lectures.github.io/intro/scipy.html#id4 This is very close to what you're trying to do. Regards St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From vbubbly21 at gmail.com Sat Oct 25 06:19:06 2014 From: vbubbly21 at gmail.com (Artur Bercik) Date: Sat, 25 Oct 2014 03:19:06 -0700 (PDT) Subject: The Gray Level Difference Vector (GLDV) Message-ID: Dear scikit-image Users: It is so nice to find The Gray Level Co-occurrence Matrix (GLCM) in scikit-image. http://scikit-image.org/docs/dev/auto_examples/plot_glcm.html However, I am interested in using The Gray Level Difference Vector (GLDV). Is not it available in scikit-image? Can someone guide me how to calculate it? Thanks in the advance. Artur Bercik -------------- next part -------------- An HTML attachment was scrubbed... URL: From ruben.fer.bus at googlemail.com Tue Oct 28 11:27:28 2014 From: ruben.fer.bus at googlemail.com (Ruben Fernandez) Date: Tue, 28 Oct 2014 08:27:28 -0700 (PDT) Subject: Postdoc position on image analysis - Max Planck Institute of Biochemistry Message-ID: <66f11a50-654a-44db-8b7b-721828a6a5a5@googlegroups.com> A postdoc position for an image analysis specialist is available at the Department of Molecular Structural Biology at the Max Planck Institute (MPI) of Biochemistry (Martinsried, Germany). The project aims to develop data processing and segmentation techniques to analyze the structures found in cryo-electron tomograms of cells containing toxic protein aggregates in the context of neurodegenerative disease. The position can be funded for up to 5 years by an ERC Synergy Grant awarded to the ToPAG (Toxic Protein AGgregation in neurodegeneration) consortium formed by four MPI-Martinsried departments. The goal of this multidisciplinary initiative is to investigate the mechanisms by which protein misfolding leads to neurodegeneration in diseases such as Alzheimer?s or Parkinson?s. The MPI of Biochemistry hosts a world-class cryo-electron microscopy center with multiple high end transmission electron microscopes (including Titan Krios, Tecnai Polara, Tecnai F20), several of which are equipped with energy filters, direct electron detectors and phase plates. The Institute also houses advanced equipment for sample preparation and ample computational resources. Applicants should hold a Ph.D. degree in Computer Science or related disciplines and experience in 3D data processing, preferably cryo-electron tomography. To apply, please send a motivation letter, CV and contact information of two referees to Wolfgang Baumeister (baumeist at biochem.mpg.de) or Rub?n Fern?ndez-Busnadiego (ruben at biochem.mpg.de). Ruben Fernandez-Busnadiego, Ph. D. Project Group Leader Max Planck Institute of Biochemistry Dept. Molecular Structural Biology Am Klopferspitz 18 82152 Martinsried Germany -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefan at sun.ac.za Tue Oct 28 10:46:50 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Tue, 28 Oct 2014 16:46:50 +0200 Subject: The Gray Level Difference Vector (GLDV) In-Reply-To: References: Message-ID: <87vbn4b6at.fsf@sun.ac.za> Dear Artur On 2014-10-25 12:19:06, Artur Bercik wrote: > It is so nice to find The Gray Level Co-occurrence Matrix (GLCM) in > scikit-image. > http://scikit-image.org/docs/dev/auto_examples/plot_glcm.html There was quite a bit of discussion around this functionality. https://github.com/scikit-image/scikit-image/issues/863 https://github.com/scikit-image/scikit-image/pull/914 https://github.com/scikit-image/scikit-image/pull/935 https://github.com/scikit-image/scikit-image/issues/899 One of the suggestions was that we rather specify offset than angle + distance. Since you are currently using the API, what is your feeling around that? > However, I am interested in using The Gray Level Difference Vector (GLDV). > Is not it available in scikit-image? > Can someone guide me how to calculate it? I'd be happy to help you implement GLDV computation, if you want. Do you have a good reference at hand? St?fan From jalopcar at gmail.com Tue Oct 28 20:38:32 2014 From: jalopcar at gmail.com (Jaime Lopez Carvajal) Date: Tue, 28 Oct 2014 17:38:32 -0700 (PDT) Subject: issue with skimage at anaconda Message-ID: Hi all, I am having problems installing scikit-image into Anaconda suite, although it comes with a prebuilt, i erased this skimage version to replace it github clone version. When I try to upgrade the skimage by console command it says this requeriment is already up to date (see attached image). but it doesnt appear at directory, as you can see (see attached image) How can I fix this issue? thanks in advance, Jaime -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: anaconda_issue.png Type: image/png Size: 30031 bytes Desc: not available URL: From stefan at sun.ac.za Tue Oct 28 21:34:43 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Wed, 29 Oct 2014 03:34:43 +0200 Subject: issue with skimage at anaconda In-Reply-To: References: Message-ID: <87vbn3acb0.fsf@sun.ac.za> On 2014-10-29 02:38:32, Jaime Lopez Carvajal wrote: > I am having problems installing scikit-image into Anaconda suite, although > it comes with a prebuilt, i erased this skimage version to replace it > github clone version. You need to place the cloned repository somewhere outsite your Python path, and then do python setup.py install (or, if you want to use pip, "pip install ." might even work) St?fan From stefan at sun.ac.za Thu Oct 30 13:23:55 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Thu, 30 Oct 2014 19:23:55 +0200 Subject: scikit-image paper: please cite and distribute Message-ID: <8761f18o9g.fsf@sun.ac.za> Hi everyone Whether we like it or not, the academic world runs on the currency of citations. Our scikit-image paper is performing OK (10 citations so far), but I know for a fact that there are many more projects using it, and that the package is not necessarily cited in their publications. I'm therefore asking that, for the benefit of the project, you distribute the paper as widely as possible and encourage those who use the software to cite it. As long as the citations roll in, the devs (many of whom are at academic institutions) can justify spending their time fixing issues and producing newly designed functionality. Thanks and regards, St?fan St?fan van der Walt, Johannes L. Sch?nberger, Juan Nunez-Iglesias, Fran?ois Boulogne, Joshua D. Warner, Neil Yager, Emmanuelle Gouillart, Tony Yu and the scikit-image contributors. scikit-image: Image processing in Python. PeerJ 2:e453 (2014) http://dx.doi.org/10.7717/peerj.453 @article{scikit-image, title = {scikit-image: image processing in {P}ython}, author = {van der Walt, {S}t?fan and {S}ch?nberger, {J}ohannes {L}. and {N}unez-{I}glesias, {J}uan and {B}oulogne, {F}ran?ois and {W}arner, {J}oshua {D}. and {Y}ager, {N}eil and {G}ouillart, {E}mmanuelle and {Y}u, {T}ony and the scikit-image contributors}, year = {2014}, month = {6}, keywords = {Image processing, Reproducible research, Education, Visualization, Open source, Python, Scientific programming}, volume = {2}, pages = {e453}, journal = {PeerJ}, issn = {2167-8359}, url = {http://dx.doi.org/10.7717/peerj.453}, doi = {10.7717/peerj.453} } From stefan at sun.ac.za Thu Oct 30 13:33:59 2014 From: stefan at sun.ac.za (Stefan van der Walt) Date: Thu, 30 Oct 2014 19:33:59 +0200 Subject: scikit-image paper: please cite and distribute In-Reply-To: <8761f18o9g.fsf@sun.ac.za> References: <8761f18o9g.fsf@sun.ac.za> Message-ID: <874mul8nso.fsf@sun.ac.za> On 2014-10-30 19:23:55, Stefan van der Walt wrote: > St?fan van der Walt, Johannes L. Sch?nberger, Juan Nunez-Iglesias, > Fran?ois Boulogne, Joshua D. Warner, Neil Yager, Emmanuelle Gouillart, > Tony Yu and the scikit-image contributors. scikit-image: Image > processing in Python. PeerJ 2:e453 (2014) > http://dx.doi.org/10.7717/peerj.453 Apologies, the correct BiBTeX: @article{scikit-image, title = {scikit-image: image processing in {P}ython}, author = {van der Walt, {S}t\'efan and {S}ch\"onberger, {J}ohannes {L}. and {Nunez-Iglesias}, {J}uan and {B}oulogne, {F}ran\c{c}ois and {W}arner, {J}oshua {D}. and {Y}ager, {N}eil and {G}ouillart, {E}mmanuelle and {Y}u, {T}ony and the scikit-image contributors}, year = {2014}, month = {6}, keywords = {Image processing, Reproducible research, Education, Visualization, Open source, Python, Scientific programming}, volume = {2}, pages = {e453}, journal = {PeerJ}, issn = {2167-8359}, url = {http://dx.doi.org/10.7717/peerj.453}, doi = {10.7717/peerj.453} } From vbubbly21 at gmail.com Fri Oct 31 14:09:36 2014 From: vbubbly21 at gmail.com (Artur Bercik) Date: Sat, 1 Nov 2014 03:09:36 +0900 Subject: The Gray Level Difference Vector (GLDV) In-Reply-To: <87vbn4b6at.fsf@sun.ac.za> References: <87vbn4b6at.fsf@sun.ac.za> Message-ID: Dear St?fan Thank you so much for your kind response to my question. I have collected the following references about GLDV. It is mentioned that GLDV is the the sum of the diagonals of the GLCM. http://www.fp.ucalgary.ca/mhallbey/gldv.htm http://www.matdat.life.ku.dk/ia/sessions/session8-4up.pdf https://workspace.imperial.ac.uk/imagingfacility/public/DefiniensReferenceBook.pdf Look forward to finding GLDV on scikit-image. Artur On Tue, Oct 28, 2014 at 11:46 PM, Stefan van der Walt wrote: > Dear Artur > > On 2014-10-25 12:19:06, Artur Bercik wrote: > > It is so nice to find The Gray Level Co-occurrence Matrix (GLCM) in > > scikit-image. > > http://scikit-image.org/docs/dev/auto_examples/plot_glcm.html > > There was quite a bit of discussion around this functionality. > > https://github.com/scikit-image/scikit-image/issues/863 > https://github.com/scikit-image/scikit-image/pull/914 > https://github.com/scikit-image/scikit-image/pull/935 > https://github.com/scikit-image/scikit-image/issues/899 > > One of the suggestions was that we rather specify offset than angle + > distance. Since you are currently using the API, what is your feeling > around that? > > > However, I am interested in using The Gray Level Difference Vector > (GLDV). > > Is not it available in scikit-image? > > Can someone guide me how to calculate it? > > I'd be happy to help you implement GLDV computation, if you want. Do > you have a good reference at hand? > > St?fan > > -- > You received this message because you are subscribed to the Google Groups > "scikit-image" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to scikit-image+unsubscribe at googlegroups.com. > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: