From vighneshbirodkar at gmail.com Sun May 1 04:48:12 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Sun, 1 May 2016 01:48:12 -0700 (PDT) Subject: blob detection and dust removal In-Reply-To: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> Message-ID: Hello Raphael What error did you get ? Can you post the traceback or the output after blob detection ? Thanks Vighnesh On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: > > hi folks, > > Got a problem removing dust and identifying blobs/crytals. Kindly see my > code below > > > from __future__ import division, print_function > import matplotlib.pyplot as plt > import numpy as np > from skimage import io, feature, color, measure, draw, img_as_float, > exposure > from skimage.filters.rank import median > from skimage.feature import blob_dog, blob_log, blob_doh > from skimage.morphology import disk > > #raw image > image_raw = > img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run > 4-2_00061cropped.tif'))) (RawImage.tif attached) > plt.imshow(image_raw) > > #converted to grayscale > > img_gray = > color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run > 4-2_00061cropped.tif')) > plt.imshow(image_gray) > > > #applied median filter to take out small dust particles. But the big dust > particle on the top right corner still persists (see median1.png attached) > img_filtered=median(img_gray,disk(10)) > plt.imshow(img_filtered) > > > #applied adapthist to make image more clearer (see adaptive.png) > > img_equalized=exposure.equalize_adapthist(img_filtered) > plt.imshow(img_equalized) > > #trying to detect the crystals/blobs. I followed the example here > http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html > But this gave an error. matplotlib was not happy with the data type > blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) > plt.imshow(blobs_doh) > > My problems are: > > 1. I could not get the dust particle out especially the really big one on > the top right. How can I get it out? > > 2. I could not detect the crystals/blobs in the image using blob_doh > > Any ideas/suggestions is highly appreciated. Thank you! > -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.t.wilson.bak at googlemail.com Sun May 1 08:49:15 2016 From: r.t.wilson.bak at googlemail.com (Robin Wilson) Date: Sun, 1 May 2016 05:49:15 -0700 (PDT) Subject: Please share your use cases In-Reply-To: References: Message-ID: If you'd like another example, then I've used scikit-image for processing satellite images to retrieve high-resolution maps of air pollution. I developed the method to do this during my PhD, and it uses scikit-image for most of the image processing parts of it, which involve edge-detection and segmentation, plus a number of more generic image processing tasks. If you'd like more details then feel free to contact me off-list, Robin On Sunday, 1 May 2016 08:14:10 UTC+1, Nadav Horesh wrote: > > My company (Visionsense) make stereoscopic medical video cameras for > endoscopic surgeries. I use a mix of opencv and scikit-image functions to > test and tune the image processing pipeline. Attached here a snapshot of a > utility I built for this purpose based on skimage widgets and plugins. As a > no-programmer, these tools are much more accessible and tailored to my > needs than the Qt widgets, and the line-profile tool is invaluable image > exploration tool. > > Nadav. > > 2016-04-13 20:49 GMT+03:00 St?fan van der Walt >: > >> Hi, everyone >> >> I am giving a talk on scikit-image soon, and would like to highlight how >> it is being used in practice. >> >> Please share your own applications with links to images or plots, or let >> me know if you spot someone else doing something cool! >> >> 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... at googlegroups.com . >> To post to this group, send email to scikit... at googlegroups.com >> . >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CABDkGQkQgf7sGpd0agAReX5MHiNUx6zohsRuoXEuzS1Gq_rQiw%40mail.gmail.com >> >> . >> For more options, visit https://groups.google.com/d/optout. >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nadavh.horesh at gmail.com Sun May 1 03:14:08 2016 From: nadavh.horesh at gmail.com (Nadav Horesh) Date: Sun, 1 May 2016 10:14:08 +0300 Subject: Please share your use cases In-Reply-To: References: Message-ID: My company (Visionsense) make stereoscopic medical video cameras for endoscopic surgeries. I use a mix of opencv and scikit-image functions to test and tune the image processing pipeline. Attached here a snapshot of a utility I built for this purpose based on skimage widgets and plugins. As a no-programmer, these tools are much more accessible and tailored to my needs than the Qt widgets, and the line-profile tool is invaluable image exploration tool. Nadav. 2016-04-13 20:49 GMT+03:00 St?fan van der Walt : > Hi, everyone > > I am giving a talk on scikit-image soon, and would like to highlight how > it is being used in practice. > > Please share your own applications with links to images or plots, or let > me know if you spot someone else doing something cool! > > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CABDkGQkQgf7sGpd0agAReX5MHiNUx6zohsRuoXEuzS1Gq_rQiw%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: surg_image1.png Type: image/png Size: 1159064 bytes Desc: not available URL: From raphael at aims.ac.za Sun May 1 16:19:27 2016 From: raphael at aims.ac.za (Raphael) Date: Sun, 1 May 2016 13:19:27 -0700 (PDT) Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> Message-ID: <9fea2463-d569-4a36-8dab-d27474442705@googlegroups.com> hi Vighnesh, This is the error I got : --------------------------------------------------------------------------TypeError Traceback (most recent call last) in () 1 blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1)----> 2 plt.imshow(blobs_doh) /usr/lib/python3/dist-packages/matplotlib/pyplot.py in imshow(X, cmap, norm, aspect, interpolation, alpha, vmin, vmax, origin, extent, shape, filternorm, filterrad, imlim, resample, url, hold, **kwargs) 2890 vmax=vmax, origin=origin, extent=extent, shape=shape, 2891 filternorm=filternorm, filterrad=filterrad,-> 2892 imlim=imlim, resample=resample, url=url, **kwargs) 2893 draw_if_interactive() 2894 finally: /usr/lib/python3/dist-packages/matplotlib/axes.py in imshow(self, X, cmap, norm, aspect, interpolation, alpha, vmin, vmax, origin, extent, shape, filternorm, filterrad, imlim, resample, url, **kwargs) 7300 filterrad=filterrad, resample=resample, **kwargs) 7301 -> 7302 im.set_data(X) 7303 im.set_alpha(alpha) 7304 self._set_artist_props(im) /usr/lib/python3/dist-packages/matplotlib/image.py in set_data(self, A) 428 if (self._A.ndim not in (2, 3) or 429 (self._A.ndim == 3 and self._A.shape[-1] not in (3, 4))):--> 430 raise TypeError("Invalid dimensions for image data") 431 432 self._imcache = None TypeError: Invalid dimensions for image data I also printed blobs_doh and discovered it was an empty array..Don't know why it should be empty... Thank you On Sunday, 1 May 2016 01:48:13 UTC-7, Vighnesh Birodkar wrote: > > Hello Raphael > > What error did you get ? Can you post the traceback or the output after > blob detection ? > > Thanks > Vighnesh > > On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >> >> hi folks, >> >> Got a problem removing dust and identifying blobs/crytals. Kindly see >> my code below >> >> >> from __future__ import division, print_function >> import matplotlib.pyplot as plt >> import numpy as np >> from skimage import io, feature, color, measure, draw, img_as_float, >> exposure >> from skimage.filters.rank import median >> from skimage.feature import blob_dog, blob_log, blob_doh >> from skimage.morphology import disk >> >> #raw image >> image_raw = >> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >> 4-2_00061cropped.tif'))) (RawImage.tif attached) >> plt.imshow(image_raw) >> >> #converted to grayscale >> >> img_gray = >> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >> 4-2_00061cropped.tif')) >> plt.imshow(image_gray) >> >> >> #applied median filter to take out small dust particles. But the big dust >> particle on the top right corner still persists (see median1.png attached) >> img_filtered=median(img_gray,disk(10)) >> plt.imshow(img_filtered) >> >> >> #applied adapthist to make image more clearer (see adaptive.png) >> >> img_equalized=exposure.equalize_adapthist(img_filtered) >> plt.imshow(img_equalized) >> >> #trying to detect the crystals/blobs. I followed the example here >> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >> But this gave an error. matplotlib was not happy with the data type >> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >> plt.imshow(blobs_doh) >> >> My problems are: >> >> 1. I could not get the dust particle out especially the really big one on >> the top right. How can I get it out? >> >> 2. I could not detect the crystals/blobs in the image using blob_doh >> >> Any ideas/suggestions is highly appreciated. Thank you! >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vighneshbirodkar at gmail.com Sun May 1 21:27:53 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Sun, 1 May 2016 18:27:53 -0700 (PDT) Subject: blob detection and dust removal In-Reply-To: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> Message-ID: <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Hello Raphael The error here is because the output of blob_doh in a numpy array of blobs, it is not an image meant for display. If you notice the example the blobs are being drawn separately inside the for loop. If no blobs are being detected, you can adjust the threshold. Lowering the threshold will make the function detect more blobs. It is clarified futher in the documentation http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh I was able to detect one blob in your image with the default threshold value. See: https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e Find the result attached. Thanks Vighnesh On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: > > hi folks, > > Got a problem removing dust and identifying blobs/crytals. Kindly see my > code below > > > from __future__ import division, print_function > import matplotlib.pyplot as plt > import numpy as np > from skimage import io, feature, color, measure, draw, img_as_float, > exposure > from skimage.filters.rank import median > from skimage.feature import blob_dog, blob_log, blob_doh > from skimage.morphology import disk > > #raw image > image_raw = > img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run > 4-2_00061cropped.tif'))) (RawImage.tif attached) > plt.imshow(image_raw) > > #converted to grayscale > > img_gray = > color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run > 4-2_00061cropped.tif')) > plt.imshow(image_gray) > > > #applied median filter to take out small dust particles. But the big dust > particle on the top right corner still persists (see median1.png attached) > img_filtered=median(img_gray,disk(10)) > plt.imshow(img_filtered) > > > #applied adapthist to make image more clearer (see adaptive.png) > > img_equalized=exposure.equalize_adapthist(img_filtered) > plt.imshow(img_equalized) > > #trying to detect the crystals/blobs. I followed the example here > http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html > But this gave an error. matplotlib was not happy with the data type > blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) > plt.imshow(blobs_doh) > > My problems are: > > 1. I could not get the dust particle out especially the really big one on > the top right. How can I get it out? > > 2. I could not detect the crystals/blobs in the image using blob_doh > > Any ideas/suggestions is highly appreciated. Thank you! > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: dust.png Type: image/png Size: 67490 bytes Desc: not available URL: From vighneshbirodkar at gmail.com Sun May 1 21:31:12 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Sun, 1 May 2016 18:31:12 -0700 (PDT) Subject: dev version installation In-Reply-To: <15d85674-3903-459f-a9a9-1ae32469dee6@googlegroups.com> References: <25621627-8a66-44c8-bac2-47df2b6895ae@googlegroups.com> <2b7816bd-1968-4d0c-9474-c5d0b32e284e@googlegroups.com> <64e392f5-f347-4d55-958c-6196b71bde37@googlegroups.com> <15d85674-3903-459f-a9a9-1ae32469dee6@googlegroups.com> Message-ID: Hello Raphael Instructions for installing the development version can be found here: http://scikit-image.org/docs/stable/install.html#running-the-development-version On Wednesday, April 27, 2016 at 7:54:50 PM UTC-4, Raphael wrote: > > hi all, > > I need help with installation of the latest version of scikit image(the > version I have is 0.11.3 kindly find attached). I currently run Ubuntu > 14.04 LTS. I'm not sure if sudo apt-get build-dep python-scikit-image > is the way to go. Any guidance will be highly appreciated. > > Thank you. > Raphael > > On Tuesday, 2 February 2016 14:11:46 UTC-8, stefanv wrote: >> >> On 2 February 2016 at 13:21, Simone Codeluppi >> wrote: >> > from $ git log HEAD^... I get: >> >> >> This output is a bit strange, so perhaps try: >> >> $ git checkout master >> $ git fetch >> $ git reset --hard origin/master >> >> St?fan >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Mon May 2 00:13:25 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Sun, 1 May 2016 21:13:25 -0700 Subject: blob detection and dust removal In-Reply-To: <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: hi Vighnesh, Thanks a bunch!! I see my error now. Actually that blob you detected a dust particle. Which operation would you suggest to erase it? I tried morphological erosion but it doesn't take it away. Thanks Raphael On 1 May 2016 at 18:27, Vighnesh Birodkar wrote: > Hello Raphael > > The error here is because the output of blob_doh in a numpy array of > blobs, it is not an image meant for display. If you notice the example the > blobs are being drawn separately inside the for loop. If no blobs are being > detected, you can adjust the threshold. Lowering the threshold will make > the function detect more blobs. It is clarified futher in the documentation > > http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh > > I was able to detect one blob in your image with the default threshold > value. See: > https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e > > Find the result attached. > > Thanks > Vighnesh > > On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: > >> hi folks, >> >> Got a problem removing dust and identifying blobs/crytals. Kindly see >> my code below >> >> >> from __future__ import division, print_function >> import matplotlib.pyplot as plt >> import numpy as np >> from skimage import io, feature, color, measure, draw, img_as_float, >> exposure >> from skimage.filters.rank import median >> from skimage.feature import blob_dog, blob_log, blob_doh >> from skimage.morphology import disk >> >> #raw image >> image_raw = >> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >> 4-2_00061cropped.tif'))) (RawImage.tif attached) >> plt.imshow(image_raw) >> >> #converted to grayscale >> >> img_gray = >> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >> 4-2_00061cropped.tif')) >> plt.imshow(image_gray) >> >> >> #applied median filter to take out small dust particles. But the big dust >> particle on the top right corner still persists (see median1.png attached) >> img_filtered=median(img_gray,disk(10)) >> plt.imshow(img_filtered) >> >> >> #applied adapthist to make image more clearer (see adaptive.png) >> >> img_equalized=exposure.equalize_adapthist(img_filtered) >> plt.imshow(img_equalized) >> >> #trying to detect the crystals/blobs. I followed the example here >> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >> But this gave an error. matplotlib was not happy with the data type >> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >> plt.imshow(blobs_doh) >> >> My problems are: >> >> 1. I could not get the dust particle out especially the really big one on >> the top right. How can I get it out? >> >> 2. I could not detect the crystals/blobs in the image using blob_doh >> >> Any ideas/suggestions is highly appreciated. Thank you! >> > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vighneshbirodkar at gmail.com Mon May 2 00:27:52 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Sun, 1 May 2016 21:27:52 -0700 (PDT) Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: Hi That really depends on your application. What's your motivation for removing these dust particles ? How are these images going to be processed further ? Thanks Vighnesh On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: > > hi Vighnesh, > > Thanks a bunch!! I see my error now. > > Actually that blob you detected a dust particle. Which operation would > you suggest to erase it? I tried morphological erosion but it doesn't take > it away. > > Thanks > Raphael > > On 1 May 2016 at 18:27, Vighnesh Birodkar > wrote: > >> Hello Raphael >> >> The error here is because the output of blob_doh in a numpy array of >> blobs, it is not an image meant for display. If you notice the example the >> blobs are being drawn separately inside the for loop. If no blobs are being >> detected, you can adjust the threshold. Lowering the threshold will make >> the function detect more blobs. It is clarified futher in the documentation >> >> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >> >> I was able to detect one blob in your image with the default threshold >> value. See: >> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >> >> Find the result attached. >> >> Thanks >> Vighnesh >> >> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >> >>> hi folks, >>> >>> Got a problem removing dust and identifying blobs/crytals. Kindly see >>> my code below >>> >>> >>> from __future__ import division, print_function >>> import matplotlib.pyplot as plt >>> import numpy as np >>> from skimage import io, feature, color, measure, draw, img_as_float, >>> exposure >>> from skimage.filters.rank import median >>> from skimage.feature import blob_dog, blob_log, blob_doh >>> from skimage.morphology import disk >>> >>> #raw image >>> image_raw = >>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>> plt.imshow(image_raw) >>> >>> #converted to grayscale >>> >>> img_gray = >>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>> 4-2_00061cropped.tif')) >>> plt.imshow(image_gray) >>> >>> >>> #applied median filter to take out small dust particles. But the big >>> dust particle on the top right corner still persists (see median1.png >>> attached) >>> img_filtered=median(img_gray,disk(10)) >>> plt.imshow(img_filtered) >>> >>> >>> #applied adapthist to make image more clearer (see adaptive.png) >>> >>> img_equalized=exposure.equalize_adapthist(img_filtered) >>> plt.imshow(img_equalized) >>> >>> #trying to detect the crystals/blobs. I followed the example here >>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>> But this gave an error. matplotlib was not happy with the data type >>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>> plt.imshow(blobs_doh) >>> >>> My problems are: >>> >>> 1. I could not get the dust particle out especially the really big one >>> on the top right. How can I get it out? >>> >>> 2. I could not detect the crystals/blobs in the image using blob_doh >>> >>> Any ideas/suggestions is highly appreciated. Thank you! >>> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image... at googlegroups.com . >> To post to this group, send email to scikit... at googlegroups.com >> . >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Mon May 2 01:07:27 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Sun, 1 May 2016 22:07:27 -0700 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: hi Vighnesh, Further processing involves getting the size and positions of real crystals (I want to use the positions to estimate the pair correlation function and then using the pair correlation function to estimate the structure factor) The image comes from a sequence of time lapse images. There are dust particles of various sizes in the images so if they are not eliminated, a false structure factor will be determined. The median filter took care of the very little ones but didn?t work for the bigger ones. Thanks a lot. Raphael On 1 May 2016 at 21:27, Vighnesh Birodkar wrote: > Hi > > That really depends on your application. What's your motivation for > removing these dust particles ? How are these images going to be processed > further ? > > Thanks > Vighnesh > > On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >> >> hi Vighnesh, >> >> Thanks a bunch!! I see my error now. >> >> Actually that blob you detected a dust particle. Which operation would >> you suggest to erase it? I tried morphological erosion but it doesn't take >> it away. >> >> Thanks >> Raphael >> >> On 1 May 2016 at 18:27, Vighnesh Birodkar wrote: >> >>> Hello Raphael >>> >>> The error here is because the output of blob_doh in a numpy array of >>> blobs, it is not an image meant for display. If you notice the example the >>> blobs are being drawn separately inside the for loop. If no blobs are being >>> detected, you can adjust the threshold. Lowering the threshold will make >>> the function detect more blobs. It is clarified futher in the documentation >>> >>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>> >>> I was able to detect one blob in your image with the default threshold >>> value. See: >>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>> >>> Find the result attached. >>> >>> Thanks >>> Vighnesh >>> >>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>> >>>> hi folks, >>>> >>>> Got a problem removing dust and identifying blobs/crytals. Kindly see >>>> my code below >>>> >>>> >>>> from __future__ import division, print_function >>>> import matplotlib.pyplot as plt >>>> import numpy as np >>>> from skimage import io, feature, color, measure, draw, img_as_float, >>>> exposure >>>> from skimage.filters.rank import median >>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>> from skimage.morphology import disk >>>> >>>> #raw image >>>> image_raw = >>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>> plt.imshow(image_raw) >>>> >>>> #converted to grayscale >>>> >>>> img_gray = >>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>> 4-2_00061cropped.tif')) >>>> plt.imshow(image_gray) >>>> >>>> >>>> #applied median filter to take out small dust particles. But the big >>>> dust particle on the top right corner still persists (see median1.png >>>> attached) >>>> img_filtered=median(img_gray,disk(10)) >>>> plt.imshow(img_filtered) >>>> >>>> >>>> #applied adapthist to make image more clearer (see adaptive.png) >>>> >>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>> plt.imshow(img_equalized) >>>> >>>> #trying to detect the crystals/blobs. I followed the example here >>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>> But this gave an error. matplotlib was not happy with the data type >>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>> plt.imshow(blobs_doh) >>>> >>>> My problems are: >>>> >>>> 1. I could not get the dust particle out especially the really big one >>>> on the top right. How can I get it out? >>>> >>>> 2. I could not detect the crystals/blobs in the image using blob_doh >>>> >>>> Any ideas/suggestions is highly appreciated. Thank you! >>>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image... at googlegroups.com. >>> To post to this group, send email to scikit... at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Mon May 2 01:09:59 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Sun, 1 May 2016 22:09:59 -0700 Subject: dev version installation In-Reply-To: References: <25621627-8a66-44c8-bac2-47df2b6895ae@googlegroups.com> <2b7816bd-1968-4d0c-9474-c5d0b32e284e@googlegroups.com> <64e392f5-f347-4d55-958c-6196b71bde37@googlegroups.com> <15d85674-3903-459f-a9a9-1ae32469dee6@googlegroups.com> Message-ID: Thanks a lot Vighnesh. Over the weekend I installed version 0.12.3 On 1 May 2016 at 18:31, Vighnesh Birodkar wrote: > Hello Raphael > > Instructions for installing the development version can be found here: > > http://scikit-image.org/docs/stable/install.html#running-the-development-version > > On Wednesday, April 27, 2016 at 7:54:50 PM UTC-4, Raphael wrote: >> >> hi all, >> >> I need help with installation of the latest version of scikit image(the >> version I have is 0.11.3 kindly find attached). I currently run Ubuntu >> 14.04 LTS. I'm not sure if sudo apt-get build-dep python-scikit-image >> is the way to go. Any guidance will be highly appreciated. >> >> Thank you. >> Raphael >> >> On Tuesday, 2 February 2016 14:11:46 UTC-8, stefanv wrote: >>> >>> On 2 February 2016 at 13:21, Simone Codeluppi >>> wrote: >>> > from $ git log HEAD^... I get: >>> >>> >>> This output is a bit strange, so perhaps try: >>> >>> $ git checkout master >>> $ git fetch >>> $ git reset --hard origin/master >>> >>> St?fan >>> >> -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/oo0ukOiuexk/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/fa6ed327-2b96-4e0e-9016-679be5f7f469%40googlegroups.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vighneshbirodkar at gmail.com Mon May 2 05:30:37 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Mon, 2 May 2016 05:30:37 -0400 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: How do you plan to find the position of the real crystals ? Maybe the function you will use to find the original crystals will take a mask argument ? On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye wrote: > hi Vighnesh, > > Further processing involves getting the size and positions of real > crystals (I want to use the positions to estimate the pair correlation > function and then using the pair correlation function to estimate the > structure factor) The image comes from a sequence of time lapse images. > There are dust particles of various sizes in the images so if they are not > eliminated, a false structure factor will be determined. The median filter > took care of the very little ones but didn?t work for the bigger ones. > > Thanks a lot. > > Raphael > > On 1 May 2016 at 21:27, Vighnesh Birodkar > wrote: > >> Hi >> >> That really depends on your application. What's your motivation for >> removing these dust particles ? How are these images going to be processed >> further ? >> >> Thanks >> Vighnesh >> >> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>> >>> hi Vighnesh, >>> >>> Thanks a bunch!! I see my error now. >>> >>> Actually that blob you detected a dust particle. Which operation would >>> you suggest to erase it? I tried morphological erosion but it doesn't take >>> it away. >>> >>> Thanks >>> Raphael >>> >>> On 1 May 2016 at 18:27, Vighnesh Birodkar wrote: >>> >>>> Hello Raphael >>>> >>>> The error here is because the output of blob_doh in a numpy array of >>>> blobs, it is not an image meant for display. If you notice the example the >>>> blobs are being drawn separately inside the for loop. If no blobs are being >>>> detected, you can adjust the threshold. Lowering the threshold will make >>>> the function detect more blobs. It is clarified futher in the documentation >>>> >>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>> >>>> I was able to detect one blob in your image with the default threshold >>>> value. See: >>>> >>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>> >>>> Find the result attached. >>>> >>>> Thanks >>>> Vighnesh >>>> >>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>> >>>>> hi folks, >>>>> >>>>> Got a problem removing dust and identifying blobs/crytals. Kindly >>>>> see my code below >>>>> >>>>> >>>>> from __future__ import division, print_function >>>>> import matplotlib.pyplot as plt >>>>> import numpy as np >>>>> from skimage import io, feature, color, measure, draw, img_as_float, >>>>> exposure >>>>> from skimage.filters.rank import median >>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>> from skimage.morphology import disk >>>>> >>>>> #raw image >>>>> image_raw = >>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>> plt.imshow(image_raw) >>>>> >>>>> #converted to grayscale >>>>> >>>>> img_gray = >>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>> 4-2_00061cropped.tif')) >>>>> plt.imshow(image_gray) >>>>> >>>>> >>>>> #applied median filter to take out small dust particles. But the big >>>>> dust particle on the top right corner still persists (see median1.png >>>>> attached) >>>>> img_filtered=median(img_gray,disk(10)) >>>>> plt.imshow(img_filtered) >>>>> >>>>> >>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>> >>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>> plt.imshow(img_equalized) >>>>> >>>>> #trying to detect the crystals/blobs. I followed the example here >>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>> But this gave an error. matplotlib was not happy with the data type >>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>> plt.imshow(blobs_doh) >>>>> >>>>> My problems are: >>>>> >>>>> 1. I could not get the dust particle out especially the really big one >>>>> on the top right. How can I get it out? >>>>> >>>>> 2. I could not detect the crystals/blobs in the image using blob_doh >>>>> >>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>> >>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "scikit-image" group. >>>> To unsubscribe from this topic, visit >>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> scikit-image... at googlegroups.com. >>>> To post to this group, send email to scikit... at googlegroups.com. >>>> To view this discussion on the web, visit >>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image+unsubscribe at googlegroups.com. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Mon May 2 15:34:42 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Mon, 2 May 2016 12:34:42 -0700 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: hi Vighnesh I plan to use this guy http://scikit-image.org/docs/dev/auto_examples/plot_regionprops.html. The documentation on regionprops ( http://scikit-image.org/docs/dev/api/skimage.measure.html#regionprops) says I can get parameters such as co-ordinate positions, equivalent diameter etc But first I need to think of a way to exclude the dust particles, that is the main challenge. Thanks Raphael On 2 May 2016 at 02:30, Vighnesh Birodkar wrote: > How do you plan to find the position of the real crystals ? Maybe the > function you will use to find the original crystals will take a mask > argument ? > > On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye wrote: > >> hi Vighnesh, >> >> Further processing involves getting the size and positions of real >> crystals (I want to use the positions to estimate the pair correlation >> function and then using the pair correlation function to estimate the >> structure factor) The image comes from a sequence of time lapse images. >> There are dust particles of various sizes in the images so if they are not >> eliminated, a false structure factor will be determined. The median filter >> took care of the very little ones but didn?t work for the bigger ones. >> >> Thanks a lot. >> >> Raphael >> >> On 1 May 2016 at 21:27, Vighnesh Birodkar >> wrote: >> >>> Hi >>> >>> That really depends on your application. What's your motivation for >>> removing these dust particles ? How are these images going to be processed >>> further ? >>> >>> Thanks >>> Vighnesh >>> >>> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>>> >>>> hi Vighnesh, >>>> >>>> Thanks a bunch!! I see my error now. >>>> >>>> Actually that blob you detected a dust particle. Which operation would >>>> you suggest to erase it? I tried morphological erosion but it doesn't take >>>> it away. >>>> >>>> Thanks >>>> Raphael >>>> >>>> On 1 May 2016 at 18:27, Vighnesh Birodkar >>>> wrote: >>>> >>>>> Hello Raphael >>>>> >>>>> The error here is because the output of blob_doh in a numpy array of >>>>> blobs, it is not an image meant for display. If you notice the example the >>>>> blobs are being drawn separately inside the for loop. If no blobs are being >>>>> detected, you can adjust the threshold. Lowering the threshold will make >>>>> the function detect more blobs. It is clarified futher in the documentation >>>>> >>>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>>> >>>>> I was able to detect one blob in your image with the default threshold >>>>> value. See: >>>>> >>>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>>> >>>>> Find the result attached. >>>>> >>>>> Thanks >>>>> Vighnesh >>>>> >>>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>>> >>>>>> hi folks, >>>>>> >>>>>> Got a problem removing dust and identifying blobs/crytals. Kindly >>>>>> see my code below >>>>>> >>>>>> >>>>>> from __future__ import division, print_function >>>>>> import matplotlib.pyplot as plt >>>>>> import numpy as np >>>>>> from skimage import io, feature, color, measure, draw, img_as_float, >>>>>> exposure >>>>>> from skimage.filters.rank import median >>>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>>> from skimage.morphology import disk >>>>>> >>>>>> #raw image >>>>>> image_raw = >>>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>>> plt.imshow(image_raw) >>>>>> >>>>>> #converted to grayscale >>>>>> >>>>>> img_gray = >>>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>> 4-2_00061cropped.tif')) >>>>>> plt.imshow(image_gray) >>>>>> >>>>>> >>>>>> #applied median filter to take out small dust particles. But the big >>>>>> dust particle on the top right corner still persists (see median1.png >>>>>> attached) >>>>>> img_filtered=median(img_gray,disk(10)) >>>>>> plt.imshow(img_filtered) >>>>>> >>>>>> >>>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>>> >>>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>>> plt.imshow(img_equalized) >>>>>> >>>>>> #trying to detect the crystals/blobs. I followed the example here >>>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>>> But this gave an error. matplotlib was not happy with the data type >>>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>>> plt.imshow(blobs_doh) >>>>>> >>>>>> My problems are: >>>>>> >>>>>> 1. I could not get the dust particle out especially the really big >>>>>> one on the top right. How can I get it out? >>>>>> >>>>>> 2. I could not detect the crystals/blobs in the image using blob_doh >>>>>> >>>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>>> >>>>> -- >>>>> You received this message because you are subscribed to a topic in the >>>>> Google Groups "scikit-image" group. >>>>> To unsubscribe from this topic, visit >>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>> . >>>>> To unsubscribe from this group and all its topics, send an email to >>>>> scikit-image... at googlegroups.com. >>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>> To view this discussion on the web, visit >>>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>>> >>>>> . >>>>> >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image+unsubscribe at googlegroups.com. >>> To post to this group, send email to scikit-image at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image+unsubscribe at googlegroups.com. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAD82iYrA%2BgP0K2zopnj8Cp_Jg7QOVVNCt9tJmsy8rSz6dAfLBg%40mail.gmail.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vighneshbirodkar at gmail.com Mon May 2 16:54:07 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Mon, 2 May 2016 16:54:07 -0400 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: regionprops takes a labelled image as input. The question still remains, how will you generate the image in which the interested regions are labelled accordingly. You need to make that part of your algorithm exclude the dust particles. On Mon, May 2, 2016 at 3:34 PM, Raphael Okoye wrote: > hi Vighnesh > > I plan to use this guy > http://scikit-image.org/docs/dev/auto_examples/plot_regionprops.html. The > documentation on regionprops ( > http://scikit-image.org/docs/dev/api/skimage.measure.html#regionprops) > says I can get parameters such as co-ordinate positions, equivalent > diameter etc > > But first I need to think of a way to exclude the dust particles, that is > the main challenge. > > Thanks > Raphael > > On 2 May 2016 at 02:30, Vighnesh Birodkar > wrote: > >> How do you plan to find the position of the real crystals ? Maybe the >> function you will use to find the original crystals will take a mask >> argument ? >> >> On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye wrote: >> >>> hi Vighnesh, >>> >>> Further processing involves getting the size and positions of real >>> crystals (I want to use the positions to estimate the pair correlation >>> function and then using the pair correlation function to estimate the >>> structure factor) The image comes from a sequence of time lapse images. >>> There are dust particles of various sizes in the images so if they are not >>> eliminated, a false structure factor will be determined. The median filter >>> took care of the very little ones but didn?t work for the bigger ones. >>> >>> Thanks a lot. >>> >>> Raphael >>> >>> On 1 May 2016 at 21:27, Vighnesh Birodkar >>> wrote: >>> >>>> Hi >>>> >>>> That really depends on your application. What's your motivation for >>>> removing these dust particles ? How are these images going to be processed >>>> further ? >>>> >>>> Thanks >>>> Vighnesh >>>> >>>> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>>>> >>>>> hi Vighnesh, >>>>> >>>>> Thanks a bunch!! I see my error now. >>>>> >>>>> Actually that blob you detected a dust particle. Which operation >>>>> would you suggest to erase it? I tried morphological erosion but it doesn't >>>>> take it away. >>>>> >>>>> Thanks >>>>> Raphael >>>>> >>>>> On 1 May 2016 at 18:27, Vighnesh Birodkar >>>>> wrote: >>>>> >>>>>> Hello Raphael >>>>>> >>>>>> The error here is because the output of blob_doh in a numpy array of >>>>>> blobs, it is not an image meant for display. If you notice the example the >>>>>> blobs are being drawn separately inside the for loop. If no blobs are being >>>>>> detected, you can adjust the threshold. Lowering the threshold will make >>>>>> the function detect more blobs. It is clarified futher in the documentation >>>>>> >>>>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>>>> >>>>>> I was able to detect one blob in your image with the default >>>>>> threshold value. See: >>>>>> >>>>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>>>> >>>>>> Find the result attached. >>>>>> >>>>>> Thanks >>>>>> Vighnesh >>>>>> >>>>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>>>> >>>>>>> hi folks, >>>>>>> >>>>>>> Got a problem removing dust and identifying blobs/crytals. Kindly >>>>>>> see my code below >>>>>>> >>>>>>> >>>>>>> from __future__ import division, print_function >>>>>>> import matplotlib.pyplot as plt >>>>>>> import numpy as np >>>>>>> from skimage import io, feature, color, measure, draw, img_as_float, >>>>>>> exposure >>>>>>> from skimage.filters.rank import median >>>>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>>>> from skimage.morphology import disk >>>>>>> >>>>>>> #raw image >>>>>>> image_raw = >>>>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>>>> plt.imshow(image_raw) >>>>>>> >>>>>>> #converted to grayscale >>>>>>> >>>>>>> img_gray = >>>>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>> 4-2_00061cropped.tif')) >>>>>>> plt.imshow(image_gray) >>>>>>> >>>>>>> >>>>>>> #applied median filter to take out small dust particles. But the big >>>>>>> dust particle on the top right corner still persists (see median1.png >>>>>>> attached) >>>>>>> img_filtered=median(img_gray,disk(10)) >>>>>>> plt.imshow(img_filtered) >>>>>>> >>>>>>> >>>>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>>>> >>>>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>>>> plt.imshow(img_equalized) >>>>>>> >>>>>>> #trying to detect the crystals/blobs. I followed the example here >>>>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>>>> But this gave an error. matplotlib was not happy with the data type >>>>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>>>> plt.imshow(blobs_doh) >>>>>>> >>>>>>> My problems are: >>>>>>> >>>>>>> 1. I could not get the dust particle out especially the really big >>>>>>> one on the top right. How can I get it out? >>>>>>> >>>>>>> 2. I could not detect the crystals/blobs in the image using blob_doh >>>>>>> >>>>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>>>> >>>>>> -- >>>>>> You received this message because you are subscribed to a topic in >>>>>> the Google Groups "scikit-image" group. >>>>>> To unsubscribe from this topic, visit >>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>> . >>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>> scikit-image... at googlegroups.com. >>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>> To view this discussion on the web, visit >>>>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>>>> >>>>>> . >>>>>> >>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>> >>>>> >>>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "scikit-image" group. >>>> To unsubscribe from this topic, visit >>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> scikit-image+unsubscribe at googlegroups.com. >>>> To post to this group, send email to scikit-image at googlegroups.com. >>>> To view this discussion on the web, visit >>>> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >>>> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image+unsubscribe at googlegroups.com. >>> To post to this group, send email to scikit-image at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image+unsubscribe at googlegroups.com. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CAD82iYrA%2BgP0K2zopnj8Cp_Jg7QOVVNCt9tJmsy8rSz6dAfLBg%40mail.gmail.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAFCvXePXM93QLh9PFO%2B9GZxTHP%3D62B8Fk%3DddFect%2BrAkfBzyag%40mail.gmail.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Tue May 3 00:48:01 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Mon, 2 May 2016 21:48:01 -0700 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: hi Vighnesh, Thats an interesting question..never really given it a thought. I think this http://scikit-image.org/docs/dev/auto_examples/plot_label.html or the help in section 3.3.4.1.2 given here http://www.scipy-lectures.org/packages/scikit-image/ might work. As how to create the mask image to mask dust particles, I'm currently not sure how to implement that in scikit image. Thanks a lot. 3.3.4.1.2 On 2 May 2016 at 13:54, Vighnesh Birodkar wrote: > regionprops takes a labelled image as input. The question still remains, > how will you generate the image in which the interested regions are > labelled accordingly. You need to make that part of your algorithm exclude > the dust particles. > > On Mon, May 2, 2016 at 3:34 PM, Raphael Okoye wrote: > >> hi Vighnesh >> >> I plan to use this guy >> http://scikit-image.org/docs/dev/auto_examples/plot_regionprops.html. >> The documentation on regionprops ( >> http://scikit-image.org/docs/dev/api/skimage.measure.html#regionprops) >> says I can get parameters such as co-ordinate positions, equivalent >> diameter etc >> >> But first I need to think of a way to exclude the dust particles, that >> is the main challenge. >> >> Thanks >> Raphael >> >> On 2 May 2016 at 02:30, Vighnesh Birodkar >> wrote: >> >>> How do you plan to find the position of the real crystals ? Maybe the >>> function you will use to find the original crystals will take a mask >>> argument ? >>> >>> On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye >>> wrote: >>> >>>> hi Vighnesh, >>>> >>>> Further processing involves getting the size and positions of real >>>> crystals (I want to use the positions to estimate the pair correlation >>>> function and then using the pair correlation function to estimate the >>>> structure factor) The image comes from a sequence of time lapse images. >>>> There are dust particles of various sizes in the images so if they are not >>>> eliminated, a false structure factor will be determined. The median filter >>>> took care of the very little ones but didn?t work for the bigger ones. >>>> >>>> Thanks a lot. >>>> >>>> Raphael >>>> >>>> On 1 May 2016 at 21:27, Vighnesh Birodkar >>>> wrote: >>>> >>>>> Hi >>>>> >>>>> That really depends on your application. What's your motivation for >>>>> removing these dust particles ? How are these images going to be processed >>>>> further ? >>>>> >>>>> Thanks >>>>> Vighnesh >>>>> >>>>> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>>>>> >>>>>> hi Vighnesh, >>>>>> >>>>>> Thanks a bunch!! I see my error now. >>>>>> >>>>>> Actually that blob you detected a dust particle. Which operation >>>>>> would you suggest to erase it? I tried morphological erosion but it doesn't >>>>>> take it away. >>>>>> >>>>>> Thanks >>>>>> Raphael >>>>>> >>>>>> On 1 May 2016 at 18:27, Vighnesh Birodkar >>>>>> wrote: >>>>>> >>>>>>> Hello Raphael >>>>>>> >>>>>>> The error here is because the output of blob_doh in a numpy array of >>>>>>> blobs, it is not an image meant for display. If you notice the example the >>>>>>> blobs are being drawn separately inside the for loop. If no blobs are being >>>>>>> detected, you can adjust the threshold. Lowering the threshold will make >>>>>>> the function detect more blobs. It is clarified futher in the documentation >>>>>>> >>>>>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>>>>> >>>>>>> I was able to detect one blob in your image with the default >>>>>>> threshold value. See: >>>>>>> >>>>>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>>>>> >>>>>>> Find the result attached. >>>>>>> >>>>>>> Thanks >>>>>>> Vighnesh >>>>>>> >>>>>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>>>>> >>>>>>>> hi folks, >>>>>>>> >>>>>>>> Got a problem removing dust and identifying blobs/crytals. Kindly >>>>>>>> see my code below >>>>>>>> >>>>>>>> >>>>>>>> from __future__ import division, print_function >>>>>>>> import matplotlib.pyplot as plt >>>>>>>> import numpy as np >>>>>>>> from skimage import io, feature, color, measure, draw, >>>>>>>> img_as_float, exposure >>>>>>>> from skimage.filters.rank import median >>>>>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>>>>> from skimage.morphology import disk >>>>>>>> >>>>>>>> #raw image >>>>>>>> image_raw = >>>>>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>>>>> plt.imshow(image_raw) >>>>>>>> >>>>>>>> #converted to grayscale >>>>>>>> >>>>>>>> img_gray = >>>>>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>> 4-2_00061cropped.tif')) >>>>>>>> plt.imshow(image_gray) >>>>>>>> >>>>>>>> >>>>>>>> #applied median filter to take out small dust particles. But the >>>>>>>> big dust particle on the top right corner still persists (see median1.png >>>>>>>> attached) >>>>>>>> img_filtered=median(img_gray,disk(10)) >>>>>>>> plt.imshow(img_filtered) >>>>>>>> >>>>>>>> >>>>>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>>>>> >>>>>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>>>>> plt.imshow(img_equalized) >>>>>>>> >>>>>>>> #trying to detect the crystals/blobs. I followed the example here >>>>>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>>>>> But this gave an error. matplotlib was not happy with the data type >>>>>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>>>>> plt.imshow(blobs_doh) >>>>>>>> >>>>>>>> My problems are: >>>>>>>> >>>>>>>> 1. I could not get the dust particle out especially the really big >>>>>>>> one on the top right. How can I get it out? >>>>>>>> >>>>>>>> 2. I could not detect the crystals/blobs in the image using blob_doh >>>>>>>> >>>>>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>>>>> >>>>>>> -- >>>>>>> You received this message because you are subscribed to a topic in >>>>>>> the Google Groups "scikit-image" group. >>>>>>> To unsubscribe from this topic, visit >>>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>>> . >>>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>>> scikit-image... at googlegroups.com. >>>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>>> To view this discussion on the web, visit >>>>>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>>>>> >>>>>>> . >>>>>>> >>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>> >>>>>> >>>>>> -- >>>>> You received this message because you are subscribed to a topic in the >>>>> Google Groups "scikit-image" group. >>>>> To unsubscribe from this topic, visit >>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>> . >>>>> To unsubscribe from this group and all its topics, send an email to >>>>> scikit-image+unsubscribe at googlegroups.com. >>>>> To post to this group, send email to scikit-image at googlegroups.com. >>>>> To view this discussion on the web, visit >>>>> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >>>>> >>>>> . >>>>> >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "scikit-image" group. >>>> To unsubscribe from this topic, visit >>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> scikit-image+unsubscribe at googlegroups.com. >>>> To post to this group, send email to scikit-image at googlegroups.com. >>>> To view this discussion on the web, visit >>>> https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com >>>> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image+unsubscribe at googlegroups.com. >>> To post to this group, send email to scikit-image at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/CAD82iYrA%2BgP0K2zopnj8Cp_Jg7QOVVNCt9tJmsy8rSz6dAfLBg%40mail.gmail.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image+unsubscribe at googlegroups.com. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CAFCvXePXM93QLh9PFO%2B9GZxTHP%3D62B8Fk%3DddFect%2BrAkfBzyag%40mail.gmail.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAD82iYo%2BxaeFKMf6vzKe5xgn8v6Jfb46j3vzqYjxGMGcqAxLFg%40mail.gmail.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From siqueiraaf at gmail.com Tue May 3 11:47:00 2016 From: siqueiraaf at gmail.com (Alexandre Fioravante de Siqueira) Date: Tue, 3 May 2016 08:47:00 -0700 (PDT) Subject: Translating Multi-Otsu Threshold from java Message-ID: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> Hi everyone, I was thinking about using multi-Otsu thresholding for some research. I am used to use the ImageJ available plugin, http://imagej.net/Multi_Otsu_Threshold. Could you give me a hand on writing such a function which could do this for python? Maybe putting it into scikit-image. Or else, could you point me a better alternative? Thank you very much! Alex -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Tue May 3 06:30:37 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Tue, 03 May 2016 10:30:37 +0000 Subject: Please share your use cases In-Reply-To: References: Message-ID: On Sun, 1 May 2016 at 00:14 Nadav Horesh wrote: > My company (Visionsense) make stereoscopic medical video cameras for > endoscopic surgeries. I use a mix of opencv and scikit-image functions to > test and tune the image processing pipeline. Attached here a snapshot of a > utility I built for this purpose based on skimage widgets and plugins. As a > no-programmer, these tools are much more accessible and tailored to my > needs than the Qt widgets, and the line-profile tool is invaluable image > exploration tool. > Thank you very much for your example, Nadav! St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From silvertrumpet999 at gmail.com Tue May 3 19:31:31 2016 From: silvertrumpet999 at gmail.com (Josh Warner) Date: Tue, 3 May 2016 16:31:31 -0700 (PDT) Subject: Please share your use cases In-Reply-To: References: Message-ID: I know of uses of the package for: - Feature extraction prior to machine learning, applied to medical images (single modality as well as registered multi-spectral images), including essentially every tool in `skimage.measure`. - Medical image segmentation of 3d and multi-spectral 3d volumes - mostly with random walker - Generation of 3d-printable meshes from volumes using marching_cubes for teaching or pre-operative visualization - Interactive line profile averaging of speleothem micrographs using the viewer - Enhancement of micrograph images, using adaptive local histogram equalization - ... oh, and panorama stitching ;) Josh On Tuesday, May 3, 2016 at 5:30:48 AM UTC-5, stefanv wrote: > > On Sun, 1 May 2016 at 00:14 Nadav Horesh wrote: > >> My company (Visionsense) make stereoscopic medical video cameras for >> endoscopic surgeries. I use a mix of opencv and scikit-image functions to >> test and tune the image processing pipeline. Attached here a snapshot of a >> utility I built for this purpose based on skimage widgets and plugins. As a >> no-programmer, these tools are much more accessible and tailored to my >> needs than the Qt widgets, and the line-profile tool is invaluable image >> exploration tool. >> > > Thank you very much for your example, Nadav! > > St?fan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From silvertrumpet999 at gmail.com Tue May 3 19:34:37 2016 From: silvertrumpet999 at gmail.com (Josh Warner) Date: Tue, 3 May 2016 16:34:37 -0700 (PDT) Subject: Translating Multi-Otsu Threshold from java In-Reply-To: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> References: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> Message-ID: We do have Otsu, and I think it would be within the scope of scikit-image. I think I'd find use for this, personally, and depending on the implementation you may be able to reuse code from simple binary Otsu internally. Seems reasonable - PR would be welcome! Josh On Tuesday, May 3, 2016 at 10:47:00 AM UTC-5, Alexandre Fioravante de Siqueira wrote: > > Hi everyone, > I was thinking about using multi-Otsu thresholding for some research. I am > used to use the ImageJ available plugin, > http://imagej.net/Multi_Otsu_Threshold. > Could you give me a hand on writing such a function which could do this > for python? Maybe putting it into scikit-image. Or else, could you point me > a better alternative? > Thank you very much! > > Alex > -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Tue May 3 22:32:05 2016 From: raphael at aims.ac.za (Raphael) Date: Tue, 3 May 2016 19:32:05 -0700 (PDT) Subject: regioinfill Message-ID: hi folks, Is there something like this http://www.mathworks.com/help/images/ref/regionfill.html found in mathlab in Scikit image? Thanks Raphael -------------- next part -------------- An HTML attachment was scrubbed... URL: From siqueiraaf at gmail.com Sun May 8 11:20:31 2016 From: siqueiraaf at gmail.com (Alexandre Fioravante de Siqueira) Date: Sun, 8 May 2016 08:20:31 -0700 (PDT) Subject: Translating Multi-Otsu Threshold from java In-Reply-To: References: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> Message-ID: <4ce0276b-b208-45e4-a8a4-b925639e6b30@googlegroups.com> Hi Josh, OK, I'm on it. I'll try to implement from the paper. Alex Em quarta-feira, 4 de maio de 2016 01:34:38 UTC+2, Josh Warner escreveu: > > We do have Otsu, and I think it would be within the scope of scikit-image. > > I think I'd find use for this, personally, and depending on the > implementation you may be able to reuse code from simple binary Otsu > internally. > > Seems reasonable - PR would be welcome! > > Josh > > On Tuesday, May 3, 2016 at 10:47:00 AM UTC-5, Alexandre Fioravante de > Siqueira wrote: >> >> Hi everyone, >> I was thinking about using multi-Otsu thresholding for some research. I >> am used to use the ImageJ available plugin, >> http://imagej.net/Multi_Otsu_Threshold. >> Could you give me a hand on writing such a function which could do this >> for python? Maybe putting it into scikit-image. Or else, could you point me >> a better alternative? >> Thank you very much! >> >> Alex >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From siqueiraaf at gmail.com Mon May 9 06:14:59 2016 From: siqueiraaf at gmail.com (Alexandre Fioravante de Siqueira) Date: Mon, 9 May 2016 03:14:59 -0700 (PDT) Subject: Translating Multi-Otsu Threshold from java In-Reply-To: <4ce0276b-b208-45e4-a8a4-b925639e6b30@googlegroups.com> References: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> <4ce0276b-b208-45e4-a8a4-b925639e6b30@googlegroups.com> Message-ID: <0027471f-101e-49cf-a5b5-a8ecdfe7216f@googlegroups.com> Hi all, the preliminary code is ready, but it could be improved a lot. For instance, there's a function named maxsigma() which has a lot of nested for loops. Here is the code: https://gist.github.com/alexandrejaguar/fd767149b3a667f8be125734893f020d Could you give me a hand to improve that? Thank you very much! Kind regards, Alex Em domingo, 8 de maio de 2016 17:20:31 UTC+2, Alexandre Fioravante de Siqueira escreveu: > > Hi Josh, > OK, I'm on it. I'll try to implement from the paper. > > Alex > > Em quarta-feira, 4 de maio de 2016 01:34:38 UTC+2, Josh Warner escreveu: >> >> We do have Otsu, and I think it would be within the scope of >> scikit-image. >> >> I think I'd find use for this, personally, and depending on the >> implementation you may be able to reuse code from simple binary Otsu >> internally. >> >> Seems reasonable - PR would be welcome! >> >> Josh >> >> On Tuesday, May 3, 2016 at 10:47:00 AM UTC-5, Alexandre Fioravante de >> Siqueira wrote: >>> >>> Hi everyone, >>> I was thinking about using multi-Otsu thresholding for some research. I >>> am used to use the ImageJ available plugin, >>> http://imagej.net/Multi_Otsu_Threshold. >>> Could you give me a hand on writing such a function which could do this >>> for python? Maybe putting it into scikit-image. Or else, could you point me >>> a better alternative? >>> Thank you very much! >>> >>> Alex >>> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From siqueiraaf at gmail.com Mon May 9 13:06:46 2016 From: siqueiraaf at gmail.com (Alexandre Fioravante de Siqueira) Date: Mon, 9 May 2016 10:06:46 -0700 (PDT) Subject: Translating Multi-Otsu Threshold from java In-Reply-To: <0027471f-101e-49cf-a5b5-a8ecdfe7216f@googlegroups.com> References: <26620e4c-ba27-46b8-a8e4-8d9daada6d90@googlegroups.com> <4ce0276b-b208-45e4-a8a4-b925639e6b30@googlegroups.com> <0027471f-101e-49cf-a5b5-a8ecdfe7216f@googlegroups.com> Message-ID: <182f6557-808f-4603-9860-35fe40cf0558@googlegroups.com> Done (for now): https://github.com/scikit-image/scikit-image/pull/2076. Em segunda-feira, 9 de maio de 2016 12:14:59 UTC+2, Alexandre Fioravante de Siqueira escreveu: > > Hi all, > the preliminary code is ready, but it could be improved a lot. For > instance, there's a function named maxsigma() which has a lot of nested for > loops. > Here is the code: > https://gist.github.com/alexandrejaguar/fd767149b3a667f8be125734893f020d > Could you give me a hand to improve that? > Thank you very much! > Kind regards, > > Alex > > Em domingo, 8 de maio de 2016 17:20:31 UTC+2, Alexandre Fioravante de > Siqueira escreveu: >> >> Hi Josh, >> OK, I'm on it. I'll try to implement from the paper. >> >> Alex >> >> Em quarta-feira, 4 de maio de 2016 01:34:38 UTC+2, Josh Warner escreveu: >>> >>> We do have Otsu, and I think it would be within the scope of >>> scikit-image. >>> >>> I think I'd find use for this, personally, and depending on the >>> implementation you may be able to reuse code from simple binary Otsu >>> internally. >>> >>> Seems reasonable - PR would be welcome! >>> >>> Josh >>> >>> On Tuesday, May 3, 2016 at 10:47:00 AM UTC-5, Alexandre Fioravante de >>> Siqueira wrote: >>>> >>>> Hi everyone, >>>> I was thinking about using multi-Otsu thresholding for some research. I >>>> am used to use the ImageJ available plugin, >>>> http://imagej.net/Multi_Otsu_Threshold. >>>> Could you give me a hand on writing such a function which could do this >>>> for python? Maybe putting it into scikit-image. Or else, could you point me >>>> a better alternative? >>>> Thank you very much! >>>> >>>> Alex >>>> >>> -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.t.wilson.bak at googlemail.com Fri May 13 05:54:51 2016 From: r.t.wilson.bak at googlemail.com (Robin Wilson) Date: Fri, 13 May 2016 02:54:51 -0700 (PDT) Subject: Most efficient way to calculate average value of labelled objects within an image Message-ID: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Hi, I have a labelled image, where each individual connected object has a unique integer value (eg. as produced from skimage.measure.label), and I want to get the mean value of these pixels from another image (eg. the image that I originally segmented before labelling). What is the most efficient way to do this? The naive way is to loop over the values in the image calculating it for each one - but I assume that numpy (or skimage itself) has a far better way of doing this... Thanks, Robin Dr Robin Wilson Research Fellow University of Southampton, UK -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.t.wilson.bak at googlemail.com Fri May 13 06:02:17 2016 From: r.t.wilson.bak at googlemail.com (Robin Wilson) Date: Fri, 13 May 2016 03:02:17 -0700 (PDT) Subject: Addition of 'Edge Drawing' and 'Edge Drawing Parameter Free' algorithms to skimage? Message-ID: <65359b72-26e4-4747-a6cf-68755dd717f4@googlegroups.com> Hi, I'm currently in the process of implementing the Edge Drawing algorithm (see http://ceng.anadolu.edu.tr/CV/EdgeDrawing/) in Python, and am just starting to implement the additions required to produce the Edge Drawing Parameter Free (http://ceng.anadolu.edu.tr/CV/EDPF/) algorithm too. In summary, these are quite interesting and useful edge detection algorithms that use a 'joining the dots' approach, and so produce nicely connected edges. The Parameter Free version also seems to work remarkably well for an algorithm that doesn't require any parameters! Would the addition of these algorithms to skimage be of interest? The implementation isn't quite finished yet, and could do with some tidying (potentially with advice from some of the skimage maintainers), but it shouldn't be too long until they are in a fit state. Cheers, Robin Dr Robin Wilson Research Fellow University of Southampton, UK -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.t.wilson.bak at googlemail.com Fri May 13 07:16:31 2016 From: r.t.wilson.bak at googlemail.com (Robin Wilson) Date: Fri, 13 May 2016 04:16:31 -0700 (PDT) Subject: Most efficient way to calculate average value of labelled objects within an image In-Reply-To: References: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Message-ID: Hi, I probably didn't explain it very well, but that was the sort of loop I meant when I said "loop over all of the values of the image calculating it for each one" (values was probably a bad choice of word, I meant individual label values). I was wondering whether there was a more efficient way to do this using some sort of clever numpy or skimage function? That is, without manually looping over each label value (ie. 0 to the number of labels). Cheers, Robin On Friday, 13 May 2016 12:01:55 UTC+1, Egor Panfilov wrote: > > Hello Robin! > > Without any doubts, there is a better way to do this. You could take a > look at the informative documentation section on Indexing ( > http://docs.scipy.org/doc/numpy/reference/arrays.indexing.html#). > > The most simple and common solution could be: > > import numpy as np > > >> arr = np.random.rand(9).reshape((3, 3)) > > labels = (arr > 0.5).astype(np.uint) > > >> print(arr) > > print(labels) > > >> for label in np.unique(labels): > > mask = labels == label > > print(label, np.mean(arr[mask])) > > > Egor > > 2016-05-13 12:54 GMT+03:00 'Robin Wilson' via scikit-image < > scikit... at googlegroups.com >: > >> Hi, >> >> I have a labelled image, where each individual connected object has a >> unique integer value (eg. as produced from skimage.measure.label), and I >> want to get the mean value of these pixels from another image (eg. the >> image that I originally segmented before labelling). >> >> What is the most efficient way to do this? The naive way is to loop over >> the values in the image calculating it for each one - but I assume that >> numpy (or skimage itself) has a far better way of doing this... >> >> Thanks, >> >> Robin >> >> Dr Robin Wilson >> Research Fellow >> University of Southampton, UK >> >> -- >> 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 . >> To post to this group, send email to scikit... at googlegroups.com >> . >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/87b5d106-00d9-44bf-a89b-bff09ca7d00b%40googlegroups.com >> >> . >> For more options, visit https://groups.google.com/d/optout. >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From tomio2009 at gmail.com Fri May 13 06:03:48 2016 From: tomio2009 at gmail.com (Tamas H.) Date: Fri, 13 May 2016 12:03:48 +0200 Subject: Most efficient way to calculate average value of labelled objects within an image In-Reply-To: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> References: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Message-ID: How about this: maskimg is the image with the labels, img is the image you want to analyze, then: for i in range(1, maskimg.max()): img[ maskimg==i].mean() ... On Fri, May 13, 2016 at 11:54 AM, 'Robin Wilson' via scikit-image < scikit-image at googlegroups.com> wrote: > Hi, > > I have a labelled image, where each individual connected object has a > unique integer value (eg. as produced from skimage.measure.label), and I > want to get the mean value of these pixels from another image (eg. the > image that I originally segmented before labelling). > > What is the most efficient way to do this? The naive way is to loop over > the values in the image calculating it for each one - but I assume that > numpy (or skimage itself) has a far better way of doing this... > > Thanks, > > Robin > > Dr Robin Wilson > Research Fellow > University of Southampton, UK > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/87b5d106-00d9-44bf-a89b-bff09ca7d00b%40googlegroups.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From multicolor.mood at gmail.com Fri May 13 15:22:21 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Fri, 13 May 2016 12:22:21 -0700 (PDT) Subject: Addition of 'Edge Drawing' and 'Edge Drawing Parameter Free' algorithms to skimage? In-Reply-To: <65359b72-26e4-4747-a6cf-68755dd717f4@googlegroups.com> References: <65359b72-26e4-4747-a6cf-68755dd717f4@googlegroups.com> Message-ID: Hi Robin! That is very interesting algorithm! Unfortunately I couldn't find free paper on it. I think there might be some performance issues for pure Python implementation. Anyways, feel free to submit a PR (even if it is still work in process) and I'll be happy to review it. Regards, Egor ???????, 13 ??? 2016 ?., 13:02:17 UTC+3 ???????????? Robin Wilson ???????: > > Hi, > > I'm currently in the process of implementing the Edge Drawing algorithm > (see http://ceng.anadolu.edu.tr/CV/EdgeDrawing/) in Python, and am just > starting to implement the additions required to produce the Edge Drawing > Parameter Free (http://ceng.anadolu.edu.tr/CV/EDPF/) algorithm too. > > In summary, these are quite interesting and useful edge detection > algorithms that use a 'joining the dots' approach, and so produce nicely > connected edges. The Parameter Free version also seems to work remarkably > well for an algorithm that doesn't require any parameters! > > Would the addition of these algorithms to skimage be of interest? > > The implementation isn't quite finished yet, and could do with some > tidying (potentially with advice from some of the skimage maintainers), but > it shouldn't be too long until they are in a fit state. > > Cheers, > > Robin > > Dr Robin Wilson > Research Fellow > University of Southampton, UK > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From r.t.wilson.bak at googlemail.com Fri May 13 15:35:30 2016 From: r.t.wilson.bak at googlemail.com (Robin Wilson) Date: Fri, 13 May 2016 12:35:30 -0700 (PDT) Subject: Addition of 'Edge Drawing' and 'Edge Drawing Parameter Free' algorithms to skimage? In-Reply-To: References: <65359b72-26e4-4747-a6cf-68755dd717f4@googlegroups.com> Message-ID: <86022f4a-bc95-4654-9d3d-ebecc8eddd37@googlegroups.com> Hi Egor, The paper on the basic ED algorithm is available at https://www.researchgate.net/profile/Cuneyt_Akinlar/publication/257466884_Edge_Drawing_A_combined_real-time_edge_and_segment_detector/links/55daba4008ae9d659491f9c0.pdf I can't find a freely available copy of the EDPF paper, but to be honest the descriptions on the websites I linked to are very similar to the paper content - exact copies in some cases! I've actually had better performance than I was expecting, and even better performance when using numba for JIT compilation. I assume I'd get similar improvements with Cython. Cheers, Robin On Friday, 13 May 2016 20:22:21 UTC+1, Egor Panfilov wrote: > > Hi Robin! > That is very interesting algorithm! Unfortunately I couldn't find free > paper on it. > I think there might be some performance issues for pure Python > implementation. > > Anyways, feel free to submit a PR (even if it is still work in process) > and I'll be happy to review it. > > Regards, > Egor > > ???????, 13 ??? 2016 ?., 13:02:17 UTC+3 ???????????? Robin Wilson ???????: >> >> Hi, >> >> I'm currently in the process of implementing the Edge Drawing algorithm >> (see http://ceng.anadolu.edu.tr/CV/EdgeDrawing/) in Python, and am just >> starting to implement the additions required to produce the Edge Drawing >> Parameter Free (http://ceng.anadolu.edu.tr/CV/EDPF/) algorithm too. >> >> In summary, these are quite interesting and useful edge detection >> algorithms that use a 'joining the dots' approach, and so produce nicely >> connected edges. The Parameter Free version also seems to work remarkably >> well for an algorithm that doesn't require any parameters! >> >> Would the addition of these algorithms to skimage be of interest? >> >> The implementation isn't quite finished yet, and could do with some >> tidying (potentially with advice from some of the skimage maintainers), but >> it shouldn't be too long until they are in a fit state. >> >> Cheers, >> >> Robin >> >> Dr Robin Wilson >> Research Fellow >> University of Southampton, UK >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From jaime.frio at gmail.com Fri May 13 07:43:22 2016 From: jaime.frio at gmail.com (=?UTF-8?Q?Jaime_Fern=C3=A1ndez_del_R=C3=ADo?=) Date: Fri, 13 May 2016 13:43:22 +0200 Subject: Most efficient way to calculate average value of labelled objects within an image In-Reply-To: References: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Message-ID: On Fri, May 13, 2016 at 1:16 PM, 'Robin Wilson' via scikit-image < scikit-image at googlegroups.com> wrote: > Hi, > > I probably didn't explain it very well, but that was the sort of loop I > meant when I said "loop over all of the values of the image calculating it > for each one" (values was probably a bad choice of word, I meant individual > label values). > > I was wondering whether there was a more efficient way to do this using > some sort of clever numpy or skimage function? That is, without manually > looping over each label value (ie. 0 to the number of labels). > There's scipy.ndimage.measurements.mean which does just that. Jaime > > Cheers, > > Robin > > On Friday, 13 May 2016 12:01:55 UTC+1, Egor Panfilov wrote: >> >> Hello Robin! >> >> Without any doubts, there is a better way to do this. You could take a >> look at the informative documentation section on Indexing ( >> http://docs.scipy.org/doc/numpy/reference/arrays.indexing.html#). >> >> The most simple and common solution could be: >> >> import numpy as np >> >> >>> arr = np.random.rand(9).reshape((3, 3)) >> >> labels = (arr > 0.5).astype(np.uint) >> >> >>> print(arr) >> >> print(labels) >> >> >>> for label in np.unique(labels): >> >> mask = labels == label >> >> print(label, np.mean(arr[mask])) >> >> >> Egor >> >> 2016-05-13 12:54 GMT+03:00 'Robin Wilson' via scikit-image < >> scikit... at googlegroups.com>: >> >>> Hi, >>> >>> I have a labelled image, where each individual connected object has a >>> unique integer value (eg. as produced from skimage.measure.label), and I >>> want to get the mean value of these pixels from another image (eg. the >>> image that I originally segmented before labelling). >>> >>> What is the most efficient way to do this? The naive way is to loop over >>> the values in the image calculating it for each one - but I assume that >>> numpy (or skimage itself) has a far better way of doing this... >>> >>> Thanks, >>> >>> Robin >>> >>> Dr Robin Wilson >>> Research Fellow >>> University of Southampton, UK >>> >>> -- >>> 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. >>> To post to this group, send email to scikit... at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/87b5d106-00d9-44bf-a89b-bff09ca7d00b%40googlegroups.com >>> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/eb3eaa76-ddbd-4a79-964e-2f479e924e57%40googlegroups.com > > . > > For more options, visit https://groups.google.com/d/optout. > -- (\__/) ( O.o) ( > <) Este es Conejo. Copia a Conejo en tu firma y ay?dale en sus planes de dominaci?n mundial. -------------- next part -------------- An HTML attachment was scrubbed... URL: From multicolor.mood at gmail.com Fri May 13 07:01:53 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Fri, 13 May 2016 14:01:53 +0300 Subject: Most efficient way to calculate average value of labelled objects within an image In-Reply-To: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> References: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Message-ID: Hello Robin! Without any doubts, there is a better way to do this. You could take a look at the informative documentation section on Indexing ( http://docs.scipy.org/doc/numpy/reference/arrays.indexing.html#). The most simple and common solution could be: import numpy as np > arr = np.random.rand(9).reshape((3, 3)) labels = (arr > 0.5).astype(np.uint) > print(arr) print(labels) > for label in np.unique(labels): mask = labels == label print(label, np.mean(arr[mask])) Egor 2016-05-13 12:54 GMT+03:00 'Robin Wilson' via scikit-image < scikit-image at googlegroups.com>: > Hi, > > I have a labelled image, where each individual connected object has a > unique integer value (eg. as produced from skimage.measure.label), and I > want to get the mean value of these pixels from another image (eg. the > image that I originally segmented before labelling). > > What is the most efficient way to do this? The naive way is to loop over > the values in the image calculating it for each one - but I assume that > numpy (or skimage itself) has a far better way of doing this... > > Thanks, > > Robin > > Dr Robin Wilson > Research Fellow > University of Southampton, UK > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/87b5d106-00d9-44bf-a89b-bff09ca7d00b%40googlegroups.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From vighneshbirodkar at gmail.com Fri May 13 19:43:06 2016 From: vighneshbirodkar at gmail.com (Vighnesh Birodkar) Date: Fri, 13 May 2016 16:43:06 -0700 (PDT) Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: Hello Sorry for not getting back sooner. As mentioned in the scipy-lectures website you can use measure.label and set the dust particle pixels to 0 and they will be ignored as the background On Tuesday, May 3, 2016 at 12:48:05 AM UTC-4, Raphael wrote: > > hi Vighnesh, > > > Thats an interesting question..never really given it a thought. I think > this http://scikit-image.org/docs/dev/auto_examples/plot_label.html or > the help in section 3.3.4.1.2 given here > http://www.scipy-lectures.org/packages/scikit-image/ might work. As how > to create the mask image to mask dust particles, I'm currently not sure how > to implement that in scikit image. > > Thanks a lot. > 3.3.4.1.2 > > On 2 May 2016 at 13:54, Vighnesh Birodkar > wrote: > >> regionprops takes a labelled image as input. The question still remains, >> how will you generate the image in which the interested regions are >> labelled accordingly. You need to make that part of your algorithm exclude >> the dust particles. >> >> On Mon, May 2, 2016 at 3:34 PM, Raphael Okoye > > wrote: >> >>> hi Vighnesh >>> >>> I plan to use this guy >>> http://scikit-image.org/docs/dev/auto_examples/plot_regionprops.html. >>> The documentation on regionprops ( >>> http://scikit-image.org/docs/dev/api/skimage.measure.html#regionprops) >>> says I can get parameters such as co-ordinate positions, equivalent >>> diameter etc >>> >>> But first I need to think of a way to exclude the dust particles, that >>> is the main challenge. >>> >>> Thanks >>> Raphael >>> >>> On 2 May 2016 at 02:30, Vighnesh Birodkar >> > wrote: >>> >>>> How do you plan to find the position of the real crystals ? Maybe the >>>> function you will use to find the original crystals will take a mask >>>> argument ? >>>> >>>> On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye >>> > wrote: >>>> >>>>> hi Vighnesh, >>>>> >>>>> Further processing involves getting the size and positions of real >>>>> crystals (I want to use the positions to estimate the pair correlation >>>>> function and then using the pair correlation function to estimate the >>>>> structure factor) The image comes from a sequence of time lapse images. >>>>> There are dust particles of various sizes in the images so if they are not >>>>> eliminated, a false structure factor will be determined. The median filter >>>>> took care of the very little ones but didn?t work for the bigger ones. >>>>> >>>>> Thanks a lot. >>>>> >>>>> Raphael >>>>> >>>>> On 1 May 2016 at 21:27, Vighnesh Birodkar >>>> > wrote: >>>>> >>>>>> Hi >>>>>> >>>>>> That really depends on your application. What's your motivation for >>>>>> removing these dust particles ? How are these images going to be processed >>>>>> further ? >>>>>> >>>>>> Thanks >>>>>> Vighnesh >>>>>> >>>>>> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>>>>>> >>>>>>> hi Vighnesh, >>>>>>> >>>>>>> Thanks a bunch!! I see my error now. >>>>>>> >>>>>>> Actually that blob you detected a dust particle. Which operation >>>>>>> would you suggest to erase it? I tried morphological erosion but it doesn't >>>>>>> take it away. >>>>>>> >>>>>>> Thanks >>>>>>> Raphael >>>>>>> >>>>>>> On 1 May 2016 at 18:27, Vighnesh Birodkar >>>>>>> wrote: >>>>>>> >>>>>>>> Hello Raphael >>>>>>>> >>>>>>>> The error here is because the output of blob_doh in a numpy array >>>>>>>> of blobs, it is not an image meant for display. If you notice the example >>>>>>>> the blobs are being drawn separately inside the for loop. If no blobs are >>>>>>>> being detected, you can adjust the threshold. Lowering the threshold will >>>>>>>> make the function detect more blobs. It is clarified futher in the >>>>>>>> documentation >>>>>>>> >>>>>>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>>>>>> >>>>>>>> I was able to detect one blob in your image with the default >>>>>>>> threshold value. See: >>>>>>>> >>>>>>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>>>>>> >>>>>>>> Find the result attached. >>>>>>>> >>>>>>>> Thanks >>>>>>>> Vighnesh >>>>>>>> >>>>>>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>>>>>> >>>>>>>>> hi folks, >>>>>>>>> >>>>>>>>> Got a problem removing dust and identifying blobs/crytals. >>>>>>>>> Kindly see my code below >>>>>>>>> >>>>>>>>> >>>>>>>>> from __future__ import division, print_function >>>>>>>>> import matplotlib.pyplot as plt >>>>>>>>> import numpy as np >>>>>>>>> from skimage import io, feature, color, measure, draw, >>>>>>>>> img_as_float, exposure >>>>>>>>> from skimage.filters.rank import median >>>>>>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>>>>>> from skimage.morphology import disk >>>>>>>>> >>>>>>>>> #raw image >>>>>>>>> image_raw = >>>>>>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>>>>>> plt.imshow(image_raw) >>>>>>>>> >>>>>>>>> #converted to grayscale >>>>>>>>> >>>>>>>>> img_gray = >>>>>>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>>> 4-2_00061cropped.tif')) >>>>>>>>> plt.imshow(image_gray) >>>>>>>>> >>>>>>>>> >>>>>>>>> #applied median filter to take out small dust particles. But the >>>>>>>>> big dust particle on the top right corner still persists (see median1.png >>>>>>>>> attached) >>>>>>>>> img_filtered=median(img_gray,disk(10)) >>>>>>>>> plt.imshow(img_filtered) >>>>>>>>> >>>>>>>>> >>>>>>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>>>>>> >>>>>>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>>>>>> plt.imshow(img_equalized) >>>>>>>>> >>>>>>>>> #trying to detect the crystals/blobs. I followed the example here >>>>>>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>>>>>> But this gave an error. matplotlib was not happy with the data type >>>>>>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>>>>>> plt.imshow(blobs_doh) >>>>>>>>> >>>>>>>>> My problems are: >>>>>>>>> >>>>>>>>> 1. I could not get the dust particle out especially the really big >>>>>>>>> one on the top right. How can I get it out? >>>>>>>>> >>>>>>>>> 2. I could not detect the crystals/blobs in the image using >>>>>>>>> blob_doh >>>>>>>>> >>>>>>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>>>>>> >>>>>>>> -- >>>>>>>> You received this message because you are subscribed to a topic in >>>>>>>> the Google Groups "scikit-image" group. >>>>>>>> To unsubscribe from this topic, visit >>>>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>>>> . >>>>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>>>> scikit-image... at googlegroups.com. >>>>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>>>> To view this discussion on the web, visit >>>>>>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>>>>>> >>>>>>>> . >>>>>>>> >>>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>>> >>>>>>> >>>>>>> -- >>>>>> You received this message because you are subscribed to a topic in >>>>>> the Google Groups "scikit-image" group. >>>>>> To unsubscribe from this topic, visit >>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>> . >>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>> scikit-image... at googlegroups.com . >>>>>> To post to this group, send email to scikit... at googlegroups.com >>>>>> . >>>>>> To view this discussion on the web, visit >>>>>> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >>>>>> >>>>>> . >>>>>> >>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>> >>>>> >>>>> -- >>>>> You received this message because you are subscribed to a topic in the >>>>> Google Groups "scikit-image" group. >>>>> To unsubscribe from this topic, visit >>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>> . >>>>> To unsubscribe from this group and all its topics, send an email to >>>>> scikit-image... at googlegroups.com . >>>>> To post to this group, send email to scikit... at googlegroups.com >>>>> . >>>>> To view this discussion on the web, visit >>>>> https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com >>>>> >>>>> . >>>>> >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "scikit-image" group. >>>> To unsubscribe from this topic, visit >>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> scikit-image... at googlegroups.com . >>>> To post to this group, send email to scikit... at googlegroups.com >>>> . >>>> To view this discussion on the web, visit >>>> https://groups.google.com/d/msgid/scikit-image/CAD82iYrA%2BgP0K2zopnj8Cp_Jg7QOVVNCt9tJmsy8rSz6dAfLBg%40mail.gmail.com >>>> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image... at googlegroups.com . >>> To post to this group, send email to scikit... at googlegroups.com >>> . >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/CAFCvXePXM93QLh9PFO%2B9GZxTHP%3D62B8Fk%3DddFect%2BrAkfBzyag%40mail.gmail.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- >> You received this message because you are subscribed to a topic in the >> Google Groups "scikit-image" group. >> To unsubscribe from this topic, visit >> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >> To unsubscribe from this group and all its topics, send an email to >> scikit-image... at googlegroups.com . >> To post to this group, send email to scikit... at googlegroups.com >> . >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CAD82iYo%2BxaeFKMf6vzKe5xgn8v6Jfb46j3vzqYjxGMGcqAxLFg%40mail.gmail.com >> >> . >> >> For more options, visit https://groups.google.com/d/optout. >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Fri May 13 19:05:52 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Fri, 13 May 2016 23:05:52 +0000 Subject: Lessons learnt while developing scikit-image Message-ID: Hi folks, I forgot to mention this, but here's a short talk I gave recently about lessons learnt while developing scikit-image: Slides: https://docs.google.com/presentation/d/1wz8ibYR_kN_P7zbaxKXEexWNAZBulX1Ep-yNTtMyzQA/edit?usp=sharing Video: https://www.youtube.com/watch?v=KRfWQtlQfS8 Perhaps you have other lessons to add? Let me know! Also, you'll see a small showcase of scikit-image usage at the end of the slides. I was thinking of adding a section to the website for those--what do you all say? Regards St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From raphael at aims.ac.za Tue May 17 02:19:58 2016 From: raphael at aims.ac.za (Raphael Okoye) Date: Mon, 16 May 2016 23:19:58 -0700 Subject: blob detection and dust removal In-Reply-To: References: <687d9e93-0b25-44a8-a19d-8ed00aefdea2@googlegroups.com> <0fd22d80-4549-470f-b61b-f48d9a8d66f5@googlegroups.com> Message-ID: No worries...thanks for your input man..I appreciate On 13 May 2016 at 16:43, Vighnesh Birodkar wrote: > Hello > > Sorry for not getting back sooner. As mentioned in the scipy-lectures > website you can use measure.label and set the dust particle pixels to 0 and > they will be ignored as the background > > On Tuesday, May 3, 2016 at 12:48:05 AM UTC-4, Raphael wrote: >> >> hi Vighnesh, >> >> >> Thats an interesting question..never really given it a thought. I think >> this http://scikit-image.org/docs/dev/auto_examples/plot_label.html or >> the help in section 3.3.4.1.2 given here >> http://www.scipy-lectures.org/packages/scikit-image/ might work. As how >> to create the mask image to mask dust particles, I'm currently not sure how >> to implement that in scikit image. >> >> Thanks a lot. >> 3.3.4.1.2 >> >> On 2 May 2016 at 13:54, Vighnesh Birodkar wrote: >> >>> regionprops takes a labelled image as input. The question still remains, >>> how will you generate the image in which the interested regions are >>> labelled accordingly. You need to make that part of your algorithm exclude >>> the dust particles. >>> >>> On Mon, May 2, 2016 at 3:34 PM, Raphael Okoye wrote: >>> >>>> hi Vighnesh >>>> >>>> I plan to use this guy >>>> http://scikit-image.org/docs/dev/auto_examples/plot_regionprops.html. >>>> The documentation on regionprops ( >>>> http://scikit-image.org/docs/dev/api/skimage.measure.html#regionprops) >>>> says I can get parameters such as co-ordinate positions, equivalent >>>> diameter etc >>>> >>>> But first I need to think of a way to exclude the dust particles, that >>>> is the main challenge. >>>> >>>> Thanks >>>> Raphael >>>> >>>> On 2 May 2016 at 02:30, Vighnesh Birodkar >>>> wrote: >>>> >>>>> How do you plan to find the position of the real crystals ? Maybe the >>>>> function you will use to find the original crystals will take a mask >>>>> argument ? >>>>> >>>>> On Mon, May 2, 2016 at 1:07 AM, Raphael Okoye >>>>> wrote: >>>>> >>>>>> hi Vighnesh, >>>>>> >>>>>> Further processing involves getting the size and positions of real >>>>>> crystals (I want to use the positions to estimate the pair correlation >>>>>> function and then using the pair correlation function to estimate the >>>>>> structure factor) The image comes from a sequence of time lapse images. >>>>>> There are dust particles of various sizes in the images so if they are not >>>>>> eliminated, a false structure factor will be determined. The median filter >>>>>> took care of the very little ones but didn?t work for the bigger ones. >>>>>> >>>>>> Thanks a lot. >>>>>> >>>>>> Raphael >>>>>> >>>>>> On 1 May 2016 at 21:27, Vighnesh Birodkar >>>>>> wrote: >>>>>> >>>>>>> Hi >>>>>>> >>>>>>> That really depends on your application. What's your motivation for >>>>>>> removing these dust particles ? How are these images going to be processed >>>>>>> further ? >>>>>>> >>>>>>> Thanks >>>>>>> Vighnesh >>>>>>> >>>>>>> On Monday, May 2, 2016 at 12:13:27 AM UTC-4, Raphael wrote: >>>>>>>> >>>>>>>> hi Vighnesh, >>>>>>>> >>>>>>>> Thanks a bunch!! I see my error now. >>>>>>>> >>>>>>>> Actually that blob you detected a dust particle. Which operation >>>>>>>> would you suggest to erase it? I tried morphological erosion but it doesn't >>>>>>>> take it away. >>>>>>>> >>>>>>>> Thanks >>>>>>>> Raphael >>>>>>>> >>>>>>>> On 1 May 2016 at 18:27, Vighnesh Birodkar >>>>>>>> wrote: >>>>>>>> >>>>>>>>> Hello Raphael >>>>>>>>> >>>>>>>>> The error here is because the output of blob_doh in a numpy array >>>>>>>>> of blobs, it is not an image meant for display. If you notice the example >>>>>>>>> the blobs are being drawn separately inside the for loop. If no blobs are >>>>>>>>> being detected, you can adjust the threshold. Lowering the threshold will >>>>>>>>> make the function detect more blobs. It is clarified futher in the >>>>>>>>> documentation >>>>>>>>> >>>>>>>>> http://scikit-image.org/docs/dev/api/skimage.feature.html#skimage.feature.blob_doh >>>>>>>>> >>>>>>>>> I was able to detect one blob in your image with the default >>>>>>>>> threshold value. See: >>>>>>>>> >>>>>>>>> https://gist.github.com/vighneshbirodkar/c16515126e648cf92f08d3319d3a023e >>>>>>>>> >>>>>>>>> Find the result attached. >>>>>>>>> >>>>>>>>> Thanks >>>>>>>>> Vighnesh >>>>>>>>> >>>>>>>>> On Saturday, April 30, 2016 at 2:02:51 AM UTC-4, Raphael wrote: >>>>>>>>> >>>>>>>>>> hi folks, >>>>>>>>>> >>>>>>>>>> Got a problem removing dust and identifying blobs/crytals. >>>>>>>>>> Kindly see my code below >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> from __future__ import division, print_function >>>>>>>>>> import matplotlib.pyplot as plt >>>>>>>>>> import numpy as np >>>>>>>>>> from skimage import io, feature, color, measure, draw, >>>>>>>>>> img_as_float, exposure >>>>>>>>>> from skimage.filters.rank import median >>>>>>>>>> from skimage.feature import blob_dog, blob_log, blob_doh >>>>>>>>>> from skimage.morphology import disk >>>>>>>>>> >>>>>>>>>> #raw image >>>>>>>>>> image_raw = >>>>>>>>>> img_as_float((io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>>>> 4-2_00061cropped.tif'))) (RawImage.tif attached) >>>>>>>>>> plt.imshow(image_raw) >>>>>>>>>> >>>>>>>>>> #converted to grayscale >>>>>>>>>> >>>>>>>>>> img_gray = >>>>>>>>>> color.rgb2gray(io.imread('/home/raphael/Documents/ScikitImage/Run >>>>>>>>>> 4-2_00061cropped.tif')) >>>>>>>>>> plt.imshow(image_gray) >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> #applied median filter to take out small dust particles. But the >>>>>>>>>> big dust particle on the top right corner still persists (see median1.png >>>>>>>>>> attached) >>>>>>>>>> img_filtered=median(img_gray,disk(10)) >>>>>>>>>> plt.imshow(img_filtered) >>>>>>>>>> >>>>>>>>>> >>>>>>>>>> #applied adapthist to make image more clearer (see adaptive.png) >>>>>>>>>> >>>>>>>>>> img_equalized=exposure.equalize_adapthist(img_filtered) >>>>>>>>>> plt.imshow(img_equalized) >>>>>>>>>> >>>>>>>>>> #trying to detect the crystals/blobs. I followed the example here >>>>>>>>>> http://scikit-image.org/docs/dev/auto_examples/features_detection/plot_blob.html >>>>>>>>>> But this gave an error. matplotlib was not happy with the data type >>>>>>>>>> blobs_doh = blob_doh(img_equalized, max_sigma=30, threshold=.1) >>>>>>>>>> plt.imshow(blobs_doh) >>>>>>>>>> >>>>>>>>>> My problems are: >>>>>>>>>> >>>>>>>>>> 1. I could not get the dust particle out especially the really >>>>>>>>>> big one on the top right. How can I get it out? >>>>>>>>>> >>>>>>>>>> 2. I could not detect the crystals/blobs in the image using >>>>>>>>>> blob_doh >>>>>>>>>> >>>>>>>>>> Any ideas/suggestions is highly appreciated. Thank you! >>>>>>>>>> >>>>>>>>> -- >>>>>>>>> You received this message because you are subscribed to a topic in >>>>>>>>> the Google Groups "scikit-image" group. >>>>>>>>> To unsubscribe from this topic, visit >>>>>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>>>>> . >>>>>>>>> To unsubscribe from this group and all its topics, send an email >>>>>>>>> to scikit-image... at googlegroups.com. >>>>>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>>>>> To view this discussion on the web, visit >>>>>>>>> https://groups.google.com/d/msgid/scikit-image/0fd22d80-4549-470f-b61b-f48d9a8d66f5%40googlegroups.com >>>>>>>>> >>>>>>>>> . >>>>>>>>> >>>>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>>>> >>>>>>>> >>>>>>>> -- >>>>>>> You received this message because you are subscribed to a topic in >>>>>>> the Google Groups "scikit-image" group. >>>>>>> To unsubscribe from this topic, visit >>>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>>> . >>>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>>> scikit-image... at googlegroups.com. >>>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>>> To view this discussion on the web, visit >>>>>>> https://groups.google.com/d/msgid/scikit-image/b9ede614-1c9d-4a22-a681-fab417250aba%40googlegroups.com >>>>>>> >>>>>>> . >>>>>>> >>>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>>> >>>>>> >>>>>> -- >>>>>> You received this message because you are subscribed to a topic in >>>>>> the Google Groups "scikit-image" group. >>>>>> To unsubscribe from this topic, visit >>>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>>> . >>>>>> To unsubscribe from this group and all its topics, send an email to >>>>>> scikit-image... at googlegroups.com. >>>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>>> To view this discussion on the web, visit >>>>>> https://groups.google.com/d/msgid/scikit-image/CAFCvXeMTH9ke7Cv%3DucywhtaWPVftbfqQwVUw0O340J4y%2B6bafA%40mail.gmail.com >>>>>> >>>>>> . >>>>>> >>>>>> For more options, visit https://groups.google.com/d/optout. >>>>>> >>>>> >>>>> -- >>>>> You received this message because you are subscribed to a topic in the >>>>> Google Groups "scikit-image" group. >>>>> To unsubscribe from this topic, visit >>>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe >>>>> . >>>>> To unsubscribe from this group and all its topics, send an email to >>>>> scikit-image... at googlegroups.com. >>>>> To post to this group, send email to scikit... at googlegroups.com. >>>>> To view this discussion on the web, visit >>>>> https://groups.google.com/d/msgid/scikit-image/CAD82iYrA%2BgP0K2zopnj8Cp_Jg7QOVVNCt9tJmsy8rSz6dAfLBg%40mail.gmail.com >>>>> >>>>> . >>>>> >>>>> For more options, visit https://groups.google.com/d/optout. >>>>> >>>> >>>> -- >>>> You received this message because you are subscribed to a topic in the >>>> Google Groups "scikit-image" group. >>>> To unsubscribe from this topic, visit >>>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>>> To unsubscribe from this group and all its topics, send an email to >>>> scikit-image... at googlegroups.com. >>>> To post to this group, send email to scikit... at googlegroups.com. >>>> To view this discussion on the web, visit >>>> https://groups.google.com/d/msgid/scikit-image/CAFCvXePXM93QLh9PFO%2B9GZxTHP%3D62B8Fk%3DddFect%2BrAkfBzyag%40mail.gmail.com >>>> >>>> . >>>> >>>> For more options, visit https://groups.google.com/d/optout. >>>> >>> >>> -- >>> You received this message because you are subscribed to a topic in the >>> Google Groups "scikit-image" group. >>> To unsubscribe from this topic, visit >>> https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. >>> To unsubscribe from this group and all its topics, send an email to >>> scikit-image... at googlegroups.com. >>> To post to this group, send email to scikit... at googlegroups.com. >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/CAD82iYo%2BxaeFKMf6vzKe5xgn8v6Jfb46j3vzqYjxGMGcqAxLFg%40mail.gmail.com >>> >>> . >>> >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/VtkzL9ZCY6Q/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/e483515c-2f96-41e3-a22a-90e0de0e1700%40googlegroups.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jni.soma at gmail.com Mon May 16 23:04:33 2016 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Tue, 17 May 2016 13:04:33 +1000 Subject: Most efficient way to calculate average value of labelled objects within an image In-Reply-To: References: <87b5d106-00d9-44bf-a89b-bff09ca7d00b@googlegroups.com> Message-ID: This seems like a job for skimage.measure.regionprops...? On Fri, May 13, 2016 at 8:03 PM, Tamas H. wrote: > How about this: maskimg is the image with the labels, img is the image you > want to analyze, then: > > for i in range(1, maskimg.max()): > img[ maskimg==i].mean() > ... > > On Fri, May 13, 2016 at 11:54 AM, 'Robin Wilson' via scikit-image < > scikit-image at googlegroups.com> wrote: > >> Hi, >> >> I have a labelled image, where each individual connected object has a >> unique integer value (eg. as produced from skimage.measure.label), and I >> want to get the mean value of these pixels from another image (eg. the >> image that I originally segmented before labelling). >> >> What is the most efficient way to do this? The naive way is to loop over >> the values in the image calculating it for each one - but I assume that >> numpy (or skimage itself) has a far better way of doing this... >> >> Thanks, >> >> Robin >> >> Dr Robin Wilson >> Research Fellow >> University of Southampton, UK >> >> -- >> 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. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/87b5d106-00d9-44bf-a89b-bff09ca7d00b%40googlegroups.com >> >> . >> For more options, visit https://groups.google.com/d/optout. >> > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAM07sM6eXVGkdh1TFLPOYYBYGjcb1Oh5WsBV%2B_445fN_JxttQg%40mail.gmail.com > > . > > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 01:17:42 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Tue, 17 May 2016 22:17:42 -0700 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: Message-ID: Note that end of life for Python 2.x is actually now-ish, and that support is being offered exactly so that industry and others have time to switch over. It does not mean that folks should aim at using 2.7 until 2020! Maintaining support for an old version of Python carries a maintenance burden that I'd like to avoid if possible. Also, once our dependencies such as numpy, scipy or matplotlib make the move, we can theoretically keep supporting 2.x for a while longer, but not *much* longer. Folks in industry often run on platforms such as Anaconda, where this will probably be a non issue by then. I'm more concerned about big clusters, University labs, etc. But even there we are now able to provide both virtual environments or Conda envs much more easily than before. St?fan On May 17, 2016 21:55, "Egor Panfilov" wrote: > Hi Stefan! > Although I'm a 3.5 user for quite a long time, many people from industry > who I'm familiar with are still using 2.7, both for R&D and deplyoment. > Let's see how thing will change. Intuitively, it's too early to get rid of > 2.7 in 2020. > > 2016-05-18 3:01 GMT+03:00 St?fan van der Walt : > >> Hi everyone >> >> Python 2.7 support has been extended to 2020. Would you agree that we >> can drop 2.7 support after that date as well? >> >> 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. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CABDkGQmJyoCWrBu%3DpV41V2-dJD0wp6mrvrqHuaYCDeYmXYeW2A%40mail.gmail.com >> >> . >> For more options, visit https://groups.google.com/d/optout. >> > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CAP0v5tn%2BojdyKOrzs8LS8_YhRHTCv1ar7zudZAVLBaLkAJaCGw%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Tue May 17 20:01:21 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 00:01:21 +0000 Subject: Dropping support for 2.7 in 2020 Message-ID: Hi everyone Python 2.7 support has been extended to 2020. Would you agree that we can drop 2.7 support after that date as well? St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 02:32:14 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 06:32:14 +0000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> Message-ID: Hi Johannes On Tue, 17 May 2016 at 23:26 Johannes Sch?nberger wrote: > Even though official support for 2.7 will be dropped on the Python side, > my feeling is that it will stick around in official linux repositories for > quite some time longer. Especially on clusters etc., as you mentioned. I > would suggest to drop 2.7 support as soon as Numpy/Scipy drops it - this is > an upper bound as we depend on it and, at the same time, numpy/scipy are > important enough libraries that should also convince the last developer to > make the switch to 3.x. > It is true that Python 2.7 will stick around beyond 2020, but it will not receive bug-fixes any longer. scikit-image 0.18 (or whatever :) will also stick around along with 2.7, and we can keep supporting that release. But for any new releases beyond that point it makes little sense to support 2.7. St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 03:07:35 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 07:07:35 +0000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160518064719.GA3031017@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> Message-ID: On Tue, 17 May 2016 at 23:47 Emmanuelle Gouillart < emmanuelle.gouillart at nsup.org> wrote: > At the moment, can you estimate the cost of supporting Python 2.7, in > terms of additional code? (I would say that testing 2.7 in CI is not a > true cost, since it represents server time and not human time) > It's probably not terribly much, but it does prohibit us from making use of newer language features as they develop. I should emphasize that I think it's perfectly reasonable to keep supporting an older release of scikit-image for 2.7, just not the latest release. St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 03:52:24 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 07:52:24 +0000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160518074002.GC3031017@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> Message-ID: On Wed, 18 May 2016 at 00:40 Emmanuelle Gouillart < emmanuelle.gouillart at nsup.org> wrote: > > > It's probably not terribly much, but it does prohibit us from making use > of > > newer language features as they develop. > > Any pointer about such new features so that ignorant people like myself > can educate themselves :-D? > Here are a few, compliments of Aaron Muerer: http://asmeurer.github.io/python3-presentation/python3-presentation.pdf > I should emphasize that I think it's perfectly reasonable to keep > > supporting an older release of scikit-image for 2.7, just not the > > latest release. > > Of course. It's possible that in 2020 we'll have reached a "stationary > state" as NumPy, and that new releases will mostly be about bug fixes and > improved documentation. But we're still on a fast growing curve, so it's > hard to know. :D Feature complete! That will be a day for celebration. St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From multicolor.mood at gmail.com Wed May 18 00:55:23 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Wed, 18 May 2016 07:55:23 +0300 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: Message-ID: Hi Stefan! Although I'm a 3.5 user for quite a long time, many people from industry who I'm familiar with are still using 2.7, both for R&D and deplyoment. Let's see how thing will change. Intuitively, it's too early to get rid of 2.7 in 2020. 2016-05-18 3:01 GMT+03:00 St?fan van der Walt : > Hi everyone > > Python 2.7 support has been extended to 2020. Would you agree that we can > drop 2.7 support after that date as well? > > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CABDkGQmJyoCWrBu%3DpV41V2-dJD0wp6mrvrqHuaYCDeYmXYeW2A%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 04:09:23 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 08:09:23 +0000 Subject: Difficulty making active contours work Message-ID: Hi everyone (And especially Emmanuelle) There was a recent StackOverflow question that I think can be addressed well by active contours: http://stackoverflow.com/questions/37234413/background-removal-masking-in-python-using-edge-detection-and-scikit-image I've tried to make our implementation work on these images, but to no avail. Do you have any advice? My attempt is here: https://gist.github.com/e4313a0ecefb5ff37106b862e6cf25f5 (Note that I added a callback into the active contours loop: if callback is not None: callback(np.array([x, y]).T) Perhaps this would be a useful addition in general?) Thanks! St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsch at demuc.de Wed May 18 02:26:20 2016 From: jsch at demuc.de (=?utf-8?Q?Johannes_Sch=C3=B6nberger?=) Date: Wed, 18 May 2016 08:26:20 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: Message-ID: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> Hi Stefan, Even though official support for 2.7 will be dropped on the Python side, my feeling is that it will stick around in official linux repositories for quite some time longer. Especially on clusters etc., as you mentioned. I would suggest to drop 2.7 support as soon as Numpy/Scipy drops it - this is an upper bound as we depend on it and, at the same time, numpy/scipy are important enough libraries that should also convince the last developer to make the switch to 3.x. Anyway, until 2020 is a long time :-) Cheers, Johannes > On May 18, 2016, at 7:17 AM, St?fan van der Walt wrote: > > Note that end of life for Python 2.x is actually now-ish, and that support is being offered exactly so that industry and others have time to switch over. It does not mean that folks should aim at using 2.7 until 2020! > > Maintaining support for an old version of Python carries a maintenance burden that I'd like to avoid if possible. > > Also, once our dependencies such as numpy, scipy or matplotlib make the move, we can theoretically keep supporting 2.x for a while longer, but not *much* longer. > > Folks in industry often run on platforms such as Anaconda, where this will probably be a non issue by then. I'm more concerned about big clusters, University labs, etc. But even there we are now able to provide both virtual environments or Conda envs much more easily than before. > > St?fan > > On May 17, 2016 21:55, "Egor Panfilov" wrote: > Hi Stefan! > Although I'm a 3.5 user for quite a long time, many people from industry who I'm familiar with are still using 2.7, both for R&D and deplyoment. > Let's see how thing will change. Intuitively, it's too early to get rid of 2.7 in 2020. > > 2016-05-18 3:01 GMT+03:00 St?fan van der Walt : > Hi everyone > > Python 2.7 support has been extended to 2020. Would you agree that we can drop 2.7 support after that date as well? > > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/CABDkGQmJyoCWrBu%3DpV41V2-dJD0wp6mrvrqHuaYCDeYmXYeW2A%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. > > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/CAP0v5tn%2BojdyKOrzs8LS8_YhRHTCv1ar7zudZAVLBaLkAJaCGw%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. > > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/CABDkGQm3bvXF45AEo1fZ8aWUQNuESaYgBRcndrzWr9OQYsE%2BjA%40mail.gmail.com. > For more options, visit https://groups.google.com/d/optout. From emmanuelle.gouillart at nsup.org Wed May 18 02:47:19 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Wed, 18 May 2016 08:47:19 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> Message-ID: <20160518064719.GA3031017@phare.normalesup.org> At the moment, can you estimate the cost of supporting Python 2.7, in terms of additional code? (I would say that testing 2.7 in CI is not a true cost, since it represents server time and not human time) Best, Emma On Wed, May 18, 2016 at 06:32:14AM +0000, St??fan van der Walt wrote: > Hi Johannes > On Tue, 17 May 2016 at 23:26 Johannes Sch??nberger wrote: > Even though official support for 2.7 will be dropped on the Python side, my > feeling is that it will stick around in official linux repositories for > quite some time longer. Especially on clusters etc., as you mentioned. I > would suggest to drop 2.7 support as soon as Numpy/Scipy drops it - this is > an upper bound as we depend on it and, at the same time, numpy/scipy are > important enough libraries that should also convince the last developer to > make the switch to 3.x. > It is true that Python 2.7 will stick around beyond 2020, but it will not > receive bug-fixes any longer. ??scikit-image 0.18 (or whatever :) will also > stick around along with 2.7, and we can keep supporting that release.?? But for > any new releases beyond that point it makes little sense to support 2.7. > St??fan From emmanuelle.gouillart at nsup.org Wed May 18 03:40:02 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Wed, 18 May 2016 09:40:02 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> Message-ID: <20160518074002.GC3031017@phare.normalesup.org> > It's probably not terribly much, but it does prohibit us from making use of > newer language features as they develop. Any pointer about such new features so that ignorant people like myself can educate themselves :-D? > I should emphasize that I think it's perfectly reasonable to keep > supporting an older release of scikit-image for 2.7, just not the > latest release. Of course. It's possible that in 2020 we'll have reached a "stationary state" as NumPy, and that new releases will mostly be about bug fixes and improved documentation. But we're still on a fast growing curve, so it's hard to know. From jillc at enthought.com Wed May 18 15:53:30 2016 From: jillc at enthought.com (jillc at enthought.com) Date: Wed, 18 May 2016 12:53:30 -0700 (PDT) Subject: SciPy2016 Message-ID: <24a7bdb3-5acc-489e-aa02-24d3aefd1c0d@googlegroups.com> **SciPy 2016 Conference (Scientific Computing with Python) Announcement** SciPy 2016 , the 15th annual Scientific Computing with Python conference, will be held July 11-17, 2016 in Austin, Texas. SciPy is a community dedicated to the advancement of scientific computing through open source Python software for mathematics, science, and engineering. The annual SciPy Conference brings together over 650 participants from industry, academia, and government to showcase their latest projects, learn from skilled users and developers, and collaborate on code development. The full program will consist of 2 days of tutorials (July 11-12), 3 days of talks (July 13-15), and 2 days of developer sprints (July 16-17). More info is available on the conference website at http://scipy2016.scipy.org (where you can sign up for the mailing list); or follow @scipyconf on Twitter. We hope you?ll join us - early bird registration is open until May 22, 2016 at http://scipy2016.scipy.org/ehome/146062/332936/?&& -------------- next part -------------- An HTML attachment was scrubbed... URL: From himanshu2014iit at gmail.com Wed May 18 04:46:59 2016 From: himanshu2014iit at gmail.com (Himanshu Mishra) Date: Wed, 18 May 2016 14:16:59 +0530 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> Message-ID: Just a pointer : Ubuntu 16.04 has officially removed Python 2 from the distribution. So yes, *people will be* moving to Python 3 now. On 18 May 2016 1:22 pm, "St?fan van der Walt" wrote: > On Wed, 18 May 2016 at 00:40 Emmanuelle Gouillart < > emmanuelle.gouillart at nsup.org> wrote: > >> >> > It's probably not terribly much, but it does prohibit us from making >> use of >> > newer language features as they develop. >> >> Any pointer about such new features so that ignorant people like myself >> can educate themselves :-D? >> > > Here are a few, compliments of Aaron Muerer: > > http://asmeurer.github.io/python3-presentation/python3-presentation.pdf > > > I should emphasize that I think it's perfectly reasonable to keep >> > supporting an older release of scikit-image for 2.7, just not the >> > latest release. >> >> Of course. It's possible that in 2020 we'll have reached a "stationary >> state" as NumPy, and that new releases will mostly be about bug fixes and >> improved documentation. But we're still on a fast growing curve, so it's >> hard to know. > > > :D Feature complete! That will be a day for celebration. > > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CABDkGQm_SE8fjU1ZiUg1kWne1eLTicjvtV14Bhp1x8fOupOQNA%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Wed May 18 10:26:14 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Wed, 18 May 2016 16:26:14 +0200 Subject: Difficulty making active contours work In-Reply-To: References: Message-ID: <20160518142614.GH3031017@phare.normalesup.org> Looks weird indeed, I looked at it quickly but couldn't make it work either. I'll try to spend more time on it tonight; in the meantime, I'm also Cc'ing Julius, who contributed the active contour model and has more experience in using such tools (I remember that setting parameters was a hairy issue). Cheers Emma On Wed, May 18, 2016 at 08:09:23AM +0000, St??fan van der Walt wrote: > Hi everyone > (And especially Emmanuelle) > There was a recent StackOverflow question that I think can be addressed well by > active contours: > http://stackoverflow.com/questions/37234413/ > background-removal-masking-in-python-using-edge-detection-and-scikit-image > I've tried to make our implementation work on these images, but to no avail.?? > Do you have any advice??? My attempt is here: > https://gist.github.com/e4313a0ecefb5ff37106b862e6cf25f5 > (Note that I added a callback into the active contours loop: > ?? ?? ?? ?? if callback is not None: > ?? ?? ?? ?? ?? ?? callback(np.array([x, y]).T) > Perhaps this would be a useful addition in general?) > Thanks! > St??fan From emmanuelle.gouillart at nsup.org Wed May 18 10:28:16 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Wed, 18 May 2016 16:28:16 +0200 Subject: Difficulty making active contours work In-Reply-To: <20160518142614.GH3031017@phare.normalesup.org> References: <20160518142614.GH3031017@phare.normalesup.org> Message-ID: <20160518142816.GI3031017@phare.normalesup.org> Sorry, wrong adress for Julius On Wed, May 18, 2016 at 04:26:14PM +0200, Emmanuelle Gouillart wrote: > Looks weird indeed, I looked at it quickly but couldn't make it work > either. I'll try to spend more time on it tonight; in the meantime, I'm > also Cc'ing Julius, who contributed the active contour model and has more > experience in using such tools (I remember that setting parameters was a > hairy issue). > Cheers > Emma > On Wed, May 18, 2016 at 08:09:23AM +0000, St??fan van der Walt wrote: > > Hi everyone > > (And especially Emmanuelle) > > There was a recent StackOverflow question that I think can be addressed well by > > active contours: > > http://stackoverflow.com/questions/37234413/ > > background-removal-masking-in-python-using-edge-detection-and-scikit-image > > I've tried to make our implementation work on these images, but to no avail.?? > > Do you have any advice??? My attempt is here: > > https://gist.github.com/e4313a0ecefb5ff37106b862e6cf25f5 > > (Note that I added a callback into the active contours loop: > > ?? ?? ?? ?? if callback is not None: > > ?? ?? ?? ?? ?? ?? callback(np.array([x, y]).T) > > Perhaps this would be a useful addition in general?) > > Thanks! > > St??fan From tcaswell at gmail.com Wed May 18 13:42:23 2016 From: tcaswell at gmail.com (Thomas Caswell) Date: Wed, 18 May 2016 17:42:23 +0000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> Message-ID: The proposed release schedule for mpl is being discussed at https://mail.python.org/pipermail/matplotlib-devel/2016-May/000374.html The key point is that 'dropping python2' only means 'for new releases', all of the existing packaged code will continue to work. How often do users want to install cutting edge skimage on top of system python2? Tom On Wed, May 18, 2016 at 4:47 AM Himanshu Mishra wrote: > Just a pointer : Ubuntu 16.04 has officially removed Python 2 from the > distribution. So yes, *people will be* moving to Python 3 now. > On 18 May 2016 1:22 pm, "St?fan van der Walt" > wrote: > >> On Wed, 18 May 2016 at 00:40 Emmanuelle Gouillart < >> emmanuelle.gouillart at nsup.org> wrote: >> >>> >>> > It's probably not terribly much, but it does prohibit us from making >>> use of >>> > newer language features as they develop. >>> >>> Any pointer about such new features so that ignorant people like myself >>> can educate themselves :-D? >>> >> >> Here are a few, compliments of Aaron Muerer: >> >> http://asmeurer.github.io/python3-presentation/python3-presentation.pdf >> >> > I should emphasize that I think it's perfectly reasonable to keep >>> > supporting an older release of scikit-image for 2.7, just not the >>> > latest release. >>> >>> Of course. It's possible that in 2020 we'll have reached a "stationary >>> state" as NumPy, and that new releases will mostly be about bug fixes and >>> improved documentation. But we're still on a fast growing curve, so it's >>> hard to know. >> >> >> :D Feature complete! That will be a day for celebration. >> >> 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. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/CABDkGQm_SE8fjU1ZiUg1kWne1eLTicjvtV14Bhp1x8fOupOQNA%40mail.gmail.com >> >> . >> For more options, visit https://groups.google.com/d/optout. >> > -- > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CANpJW-URfDAKKzmbeLQz5%3DksxjJ8QbFCU2Hdm4bedZ2zx1AAAw%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Wed May 18 13:54:55 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Wed, 18 May 2016 19:54:55 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> Message-ID: <20160518175455.GA4080630@phare.normalesup.org> On Wed, May 18, 2016 at 05:42:23PM +0000, Thomas Caswell wrote: > The proposed release schedule for mpl is being discussed at??https:// > mail.python.org/pipermail/matplotlib-devel/2016-May/000374.html > The key point is that 'dropping python2' only means 'for new releases', all of > the existing packaged code will continue to work.?? How often do users want to > install cutting edge skimage on top of system python2? It happened to me yesterday :-). When I wanted to install 0.12 on a server at the synchrotron, where they have powerful stations really useful for my processing pipeline, but they are running Debian Wheezy and don't have ipython or matplotlib for python3. Also on such machines, I only have ssh access, no http/s, so no pip install... Such situations are not so unusual in the industry / at large facilities. Cheers, Emma From nelle.varoquaux at gmail.com Wed May 18 14:06:35 2016 From: nelle.varoquaux at gmail.com (Nelle Varoquaux) Date: Wed, 18 May 2016 20:06:35 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160518175455.GA4080630@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> Message-ID: On 18 May 2016 at 19:54, Emmanuelle Gouillart wrote: > On Wed, May 18, 2016 at 05:42:23PM +0000, Thomas Caswell wrote: >> The proposed release schedule for mpl is being discussed at https:// >> mail.python.org/pipermail/matplotlib-devel/2016-May/000374.html > >> The key point is that 'dropping python2' only means 'for new releases', all of >> the existing packaged code will continue to work. How often do users want to >> install cutting edge skimage on top of system python2? > > It happened to me yesterday :-). When I wanted to install 0.12 on a > server at the synchrotron, where they have powerful stations really > useful for my processing pipeline, but they are running Debian Wheezy and > don't have ipython or matplotlib for python3. Also on such machines, I > only have ssh access, no http/s, so no pip install... Such situations are > not so unusual in the industry / at large facilities. I think that still happens to a lot of people. In the two institutes I currently work at, one has recently moved from python 2.3 to python 2.6, and the other one from python 2.6 to python 2.7. In both cases, it took around 8 years to have an OS upgrade, so I wouldn't hold my breath for a new one any time soon. Cheers, N > > Cheers, > Emma > > -- > 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. > To post to this group, send an email to scikit-image at googlegroups.com. > To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/20160518175455.GA4080630%40phare.normalesup.org. > For more options, visit https://groups.google.com/d/optout. From stefanv at berkeley.edu Wed May 18 16:58:57 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 20:58:57 +0000 Subject: SciPy2016 In-Reply-To: <24a7bdb3-5acc-489e-aa02-24d3aefd1c0d@googlegroups.com> References: <24a7bdb3-5acc-489e-aa02-24d3aefd1c0d@googlegroups.com> Message-ID: On Wed, 18 May 2016 at 12:53 wrote: > **SciPy 2016 Conference (Scientific Computing with Python) Announcement** > Including a scikit-image tutorial on day two! -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Wed May 18 19:35:55 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Wed, 18 May 2016 23:35:55 +0000 Subject: Migration of mailing list to @python.org Message-ID: Hi, everyone I would like to migrate the mailing list over to mailman on Python.org. We're currently on Google Groups, but we don't have good archives or predictable permalinks based on message-id, and message export is a pain (I've scraped the entire list content, but needless to say that is less than ideal). I will port the content and automatically subscribe existing members. Let me know if you have any objections. Best regards St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Thu May 19 02:13:59 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Thu, 19 May 2016 08:13:59 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160518175455.GA4080630@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> Message-ID: <20160519061359.GB838334@phare.normalesup.org> Just to be clear: I very much hope that we'll have lots of great releases until 2020 so that users bound to legacy 2.7 will be happy with a not-so-up-to-date release. It's just that I trust us more to produce these releases than big institutions to make their systems evolve! On Wed, May 18, 2016 at 07:54:55PM +0200, Emmanuelle Gouillart wrote: > On Wed, May 18, 2016 at 05:42:23PM +0000, Thomas Caswell wrote: > > The proposed release schedule for mpl is being discussed at??https:// > > mail.python.org/pipermail/matplotlib-devel/2016-May/000374.html > > The key point is that 'dropping python2' only means 'for new releases', all of > > the existing packaged code will continue to work.?? How often do users want to > > install cutting edge skimage on top of system python2? > It happened to me yesterday :-). When I wanted to install 0.12 on a > server at the synchrotron, where they have powerful stations really > useful for my processing pipeline, but they are running Debian Wheezy and > don't have ipython or matplotlib for python3. Also on such machines, I > only have ssh access, no http/s, so no pip install... Such situations are > not so unusual in the industry / at large facilities. > Cheers, > Emma From stefanv at berkeley.edu Thu May 19 04:19:57 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Thu, 19 May 2016 08:19:57 +0000 Subject: Difficulty making active contours work In-Reply-To: <20160519074352.GC838334@phare.normalesup.org> References: <20160518142614.GH3031017@phare.normalesup.org> <20160518142816.GI3031017@phare.normalesup.org> <20160519074352.GC838334@phare.normalesup.org> Message-ID: Hi Emmanuelle On Thu, 19 May 2016 at 00:43 Emmanuelle Gouillart < emmanuelle.gouillart at nsup.org> wrote: > it seems that the main problem was that you did not have enough points > for the contour (only 4, and I think the algorithm keeps the number of > points constant). I guess we should either document that we need a large > number of points, or automatically interpolate between points. I also > padded the image with light values at the top and bottom to retrieve the > upper and lower edges, played a bit with parameters, and ended up with a > quite satisfying result > https://gist.github.com/emmanuelle/c741f9656d3e70efbd736bb32d75fee6 Thanks for looking at this. That was quite a surprise--we should definitely document it. https://github.com/scikit-image/scikit-image/issues/2093 I modified the border values a bit, I think row & column was swapped. But then, removing the Gaussian filter, I could not get it to converge again: https://gist.github.com/4afa874fccdb40e97cb8df0d20053547 If the algorithm is that sensitive to parameters, I'm sure there must have been suggestions in literature on how to improve upon it. Best regards St?fan > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Thu May 19 03:43:52 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Thu, 19 May 2016 09:43:52 +0200 Subject: Difficulty making active contours work In-Reply-To: <20160518142816.GI3031017@phare.normalesup.org> References: <20160518142614.GH3031017@phare.normalesup.org> <20160518142816.GI3031017@phare.normalesup.org> Message-ID: <20160519074352.GC838334@phare.normalesup.org> Hi St??fan, it seems that the main problem was that you did not have enough points for the contour (only 4, and I think the algorithm keeps the number of points constant). I guess we should either document that we need a large number of points, or automatically interpolate between points. I also padded the image with light values at the top and bottom to retrieve the upper and lower edges, played a bit with parameters, and ended up with a quite satisfying result https://gist.github.com/emmanuelle/c741f9656d3e70efbd736bb32d75fee6 Anyway, parameter selection is quite hard for this function, we should ass more documentation / examples. Cheers, Emma On Wed, May 18, 2016 at 04:28:16PM +0200, Emmanuelle Gouillart wrote: > Sorry, wrong adress for Julius > On Wed, May 18, 2016 at 04:26:14PM +0200, Emmanuelle Gouillart wrote: > > Looks weird indeed, I looked at it quickly but couldn't make it work > > either. I'll try to spend more time on it tonight; in the meantime, I'm > > also Cc'ing Julius, who contributed the active contour model and has more > > experience in using such tools (I remember that setting parameters was a > > hairy issue). > > Cheers > > Emma > > On Wed, May 18, 2016 at 08:09:23AM +0000, St??fan van der Walt wrote: > > > Hi everyone > > > (And especially Emmanuelle) > > > There was a recent StackOverflow question that I think can be addressed well by > > > active contours: > > > http://stackoverflow.com/questions/37234413/ > > > background-removal-masking-in-python-using-edge-detection-and-scikit-image > > > I've tried to make our implementation work on these images, but to no avail.?? > > > Do you have any advice??? My attempt is here: > > > https://gist.github.com/e4313a0ecefb5ff37106b862e6cf25f5 > > > (Note that I added a callback into the active contours loop: > > > ?? ?? ?? ?? if callback is not None: > > > ?? ?? ?? ?? ?? ?? callback(np.array([x, y]).T) > > > Perhaps this would be a useful addition in general?) > > > Thanks! > > > St??fan From fboulogne at sciunto.org Thu May 19 05:20:42 2016 From: fboulogne at sciunto.org (=?UTF-8?Q?Fran=c3=a7ois_Boulogne?=) Date: Thu, 19 May 2016 11:20:42 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160519061359.GB838334@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160519061359.GB838334@phare.normalesup.org> Message-ID: > It's just that I trust us more to produce > these releases than big institutions to make their systems evolve! :) To add a little piece to the thoughts shared on this question, we may wonder if there was or there is or there will be soon a feature to implement that would cause a lot of pain to make it work with python 2.7. We may also wonder if for those users who need to use old systems, will it be possible to install scikitimage if we constantly increase the minimal version of our dependencies (cython etc). If they are not also available on their system, it means that in practice, they will need to stuck on an older version of scikit-image anyway. I never learned python2, but I don't know the nice features of python3 only because I can't contribute with them. That's sad. -- Fran?ois Boulogne. http://www.sciunto.org GPG: 32D5F22F From nabil.freij at gmail.com Thu May 19 10:25:54 2016 From: nabil.freij at gmail.com (Nabil Freij) Date: Thu, 19 May 2016 16:25:54 +0200 Subject: Thresholding a dark region in an image Message-ID: Hello, I have been investigating how to threshold a structure in my images. More specifically, a sunspot, that can be seen in Figure 1. The aim has been to isolate and measure the number of pixels that are part of the central part of a sunspot, which is the darkest region of the structure. The method I have been using is to define a region which contains no features that are similar to a sunspot. The size of this region is not fixed but I generally make it as large as the data allows. This region is at the bottom black box in Figure 1 (ignore the slider). The mean and standard deviation of this region is calculated, which allows me to define a threshold limit, which is subtracting the standard deviation multiplied by a user defined constant from the mean. The constant is chosen so that overall, the threshold is selecting the pixels we know that are part of the central region. But this value varies depending the structure and the data source. Another method I have discussed or looked into are related to Figure 2. On the left is a cropped field of view of the sunspot and on the right is a histogram of this image in red and in yellow is the histogram of the background box from Figure 1. By using the histogram, I can work out the numerical gradient and pick the points with the largest shift. I also tried this method on the original image by taking slices along the sunspot, however, due to the non-uniform nature of a sunspot the results were not very good. I was wondering if there were any suggestions to threshold this region that is not as ad hoc as my method? Thanks, Nabil -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: figure_1.png Type: image/png Size: 1255460 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: figure_2.png Type: image/png Size: 226214 bytes Desc: not available URL: From njs at vorpus.org Fri May 20 05:16:25 2016 From: njs at vorpus.org (Nathaniel Smith) Date: Fri, 20 May 2016 02:16:25 -0700 (PDT) Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160518175455.GA4080630@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> Message-ID: On Wednesday, May 18, 2016 at 10:54:57 AM UTC-7, Emmanuelle Gouillart wrote: > > On Wed, May 18, 2016 at 05:42:23PM +0000, Thomas Caswell wrote: > > The proposed release schedule for mpl is being discussed at https:// > > mail.python.org/pipermail/matplotlib-devel/2016-May/000374.html > > > The key point is that 'dropping python2' only means 'for new releases', > all of > > the existing packaged code will continue to work. How often do users > want to > > install cutting edge skimage on top of system python2? > > It happened to me yesterday :-). When I wanted to install 0.12 on a > server at the synchrotron, where they have powerful stations really > useful for my processing pipeline, but they are running Debian Wheezy and > don't have ipython or matplotlib for python3. Also on such machines, I > only have ssh access, no http/s, so no pip install... Such situations are > not so unusual in the industry / at large facilities. > FYI, if you can copy files to the server at all, then this is easy to solve -- just download and copy over this one file, http://repo.continuum.io/archive/Anaconda3-4.0.0-Linux-x86_64.sh run it, and bam, complete up-to-date python scientific stack, no need to bother the sysadmins. I actually recommend this in general for everyone trying to do work on weird old institutional OSes, regardless of whether they need python 3 in particular -- life is too short to waste time fiddling with some ancient version of matplotlib or buggy scipy or whatever when you have real work to get done. Stable distributions are great for providing a stable baseline for the background tools that don't really matter, but if you're a scientific programmer then your python environment is too important; you need more control than that. -n -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Fri May 20 06:50:49 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Fri, 20 May 2016 12:50:49 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> Message-ID: <20160520105049.GA3583487@phare.normalesup.org> > FYI, if you can copy files to the server at all, then this is easy to solve -- > just download and copy over this one file, > ?? http://repo.continuum.io/archive/Anaconda3-4.0.0-Linux-x86_64.sh > run it, and bam, complete up-to-date python scientific stack, no need to bother > the sysadmins. > I actually recommend this in general for everyone trying to do work on weird > old institutional OSes, regardless of whether they need python 3 in particular > -- life is too short to waste time fiddling with some ancient version of > matplotlib or buggy scipy or whatever when you have real work to get done. > Stable distributions are great for providing a stable baseline for the > background tools that don't really matter, but if you're a scientific > programmer then your python environment is too important; you need more control > than that. Thanks for the tip; indeed I almost resorted to this solution, but tweaking a little bit scikit-image's setup.py and requirements.txt was faster :-) (if not cleaner). It's very good to have Anaconda in such cases, as a last resort solution. The downside is that we lose the modularity of the scientific Python ecosystem, having to use a whole distribution in a very monolithic way. I used to think that Anaconda was mostly for these Windows people :-)... Cheers, Emma From stuart at cadair.com Fri May 20 08:15:33 2016 From: stuart at cadair.com (Stuart Mumford) Date: Fri, 20 May 2016 13:15:33 +0100 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160520105049.GA3583487@phare.normalesup.org> References: <44DF554C-1210-44CC-8C3D-1D3ACFF6A587@demuc.de> <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160520105049.GA3583487@phare.normalesup.org> Message-ID: Hi, > It's very good to have Anaconda in such cases, as a last resort solution. > The downside is that we lose the modularity of the scientific Python > ecosystem, having to use a whole distribution in a very monolithic way. There is always miniconda which only installs Python and conda, which means you can build up your own environments. Somewhat off topic, but we have a nice centralised installation of miniconda on our cluster at Sheffield. (http://docs.iceberg.shef.ac.uk/en/latest/software/apps/python.html) On topic, I am all for not releasing new (non-bug fix) versions of libraries with Python 2.7 support in or even before 2020. Stuart From msarahan at gmail.com Fri May 20 10:29:51 2016 From: msarahan at gmail.com (Michael Sarahan) Date: Fri, 20 May 2016 14:29:51 +0000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: <20160520141800.GD3583487@phare.normalesup.org> References: <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160520105049.GA3583487@phare.normalesup.org> <20160520141800.GD3583487@phare.normalesup.org> Message-ID: There is also Constructor, which helps you create your own miniconda-like installers with only the packages you actually want: https://github.com/conda/constructor It may save you some steps with installing miniconda, then installing other packages. I don't think this is a concern for cython or scikit-image, but many people at bumping into the language support limit in the C++11 sense with Python 2.7 on Windows. Since VS 2008 is the de-facto standard compiler for Python 2.7, people are unable to use C++11 code in modules for Python 2.7. Some people use newer compilers anyway, which sometimes works, but is mixing runtimes, and can lead to bugs or crashes. Many people would like to support Python 2.7 using a different compiler for the whole ecosystem. One example is Ilastik, by folks at HHMI, using VS 2012 to have a custom stack: https://github.com/ilastik/ilastik-build-conda Perhaps not central to this discussion, but something to be aware of. On Fri, May 20, 2016 at 9:18 AM Emmanuelle Gouillart < emmanuelle.gouillart at nsup.org> wrote: > On Fri, May 20, 2016 at 01:15:33PM +0100, Stuart Mumford wrote: > > Hi, > > > It's very good to have Anaconda in such cases, as a last resort > solution. > > > The downside is that we lose the modularity of the scientific Python > > > ecosystem, having to use a whole distribution in a very monolithic way. > > > There is always miniconda which only installs Python and conda, which > > means you can build up your own environments. Somewhat off topic, but we > > have a nice centralised installation of miniconda on our cluster at > > Sheffield. > > (http://docs.iceberg.shef.ac.uk/en/latest/software/apps/python.html) > > Thanks, I should give it a try. > > -- > 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. > To post to this group, send an email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/20160520141800.GD3583487%40phare.normalesup.org > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From emmanuelle.gouillart at nsup.org Fri May 20 10:18:00 2016 From: emmanuelle.gouillart at nsup.org (Emmanuelle Gouillart) Date: Fri, 20 May 2016 16:18:00 +0200 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160520105049.GA3583487@phare.normalesup.org> Message-ID: <20160520141800.GD3583487@phare.normalesup.org> On Fri, May 20, 2016 at 01:15:33PM +0100, Stuart Mumford wrote: > Hi, > > It's very good to have Anaconda in such cases, as a last resort solution. > > The downside is that we lose the modularity of the scientific Python > > ecosystem, having to use a whole distribution in a very monolithic way. > There is always miniconda which only installs Python and conda, which > means you can build up your own environments. Somewhat off topic, but we > have a nice centralised installation of miniconda on our cluster at > Sheffield. > (http://docs.iceberg.shef.ac.uk/en/latest/software/apps/python.html) Thanks, I should give it a try. From njs at vorpus.org Fri May 20 22:20:36 2016 From: njs at vorpus.org (Nathaniel Smith) Date: Fri, 20 May 2016 19:20:36 -0700 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160520105049.GA3583487@phare.normalesup.org> <20160520141800.GD3583487@phare.normalesup.org> Message-ID: On May 20, 2016 07:30, "Michael Sarahan" wrote: > I don't think this is a concern for cython or scikit-image, but many people at bumping into the language support limit in the C++11 sense with Python 2.7 on Windows. Since VS 2008 is the de-facto standard compiler for Python 2.7, people are unable to use C++11 code in modules for Python 2.7. Some people use newer compilers anyway, which sometimes works, but is mixing runtimes, and can lead to bugs or crashes. Many people would like to support Python 2.7 using a different compiler for the whole ecosystem. One example is Ilastik, by folks at HHMI, using VS 2012 to have a custom stack: https://github.com/ilastik/ilastik-build-conda I think getting mingwpy finished and polished is probably an easier solution for this problem than forking the entire py27-on-windows ecosystem :-) -n -------------- next part -------------- An HTML attachment was scrubbed... URL: From jalopcar at gmail.com Sat May 21 11:59:56 2016 From: jalopcar at gmail.com (Jaime Lopez Carvajal) Date: Sat, 21 May 2016 08:59:56 -0700 (PDT) Subject: Watershed segmentation problem Message-ID: <6ed8b8dd-2998-421c-951f-c1bbdf41bd8c@googlegroups.com> Hi, I want to get the watershed segmentation of remote sensing image (500 x 500 pixels) Following the @stefan-van-der-walt stackoverflow post (http://stackoverflow.com/questions/29573126/image-boundary-finding-and-filling), I can not get correct segmentation (see attached file) I am getting the coordinates images using >> coordinates = peak_local_max(image, min distance = 3), and then binarizing to have only 0 and 1 values. >> result = morphology.watershed(1 - distance_map, markers=marker_image) I use coordinates to get markers image. What could I am doing wrong? Any suggestion? Thanks in advance, Jaime -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: wateshed problem.png Type: image/png Size: 420837 bytes Desc: not available URL: From multicolor.mood at gmail.com Sun May 22 06:30:26 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Sun, 22 May 2016 03:30:26 -0700 (PDT) Subject: Difficulty making active contours work In-Reply-To: References: <20160518142614.GH3031017@phare.normalesup.org> <20160518142816.GI3031017@phare.normalesup.org> <20160519074352.GC838334@phare.normalesup.org> Message-ID: <7b3326c6-e250-4350-89ee-260b472b6fc7@googlegroups.com> +1 from me side. I never succeeded to get the positive result out of the implementation. See the attached images for the output of your, Stefan, script on the randomly chosen image. Regards, Egor ???????, 19 ??? 2016 ?., 11:20:10 UTC+3 ???????????? stefanv ???????: > > Hi Emmanuelle > > > On Thu, 19 May 2016 at 00:43 Emmanuelle Gouillart > wrote: > >> it seems that the main problem was that you did not have enough points >> for the contour (only 4, and I think the algorithm keeps the number of >> points constant). I guess we should either document that we need a large >> number of points, or automatically interpolate between points. I also >> padded the image with light values at the top and bottom to retrieve the >> upper and lower edges, played a bit with parameters, and ended up with a >> quite satisfying result >> https://gist.github.com/emmanuelle/c741f9656d3e70efbd736bb32d75fee6 > > > Thanks for looking at this. That was quite a surprise--we should > definitely document it. > > https://github.com/scikit-image/scikit-image/issues/2093 > > I modified the border values a bit, I think row & column was swapped. But > then, removing the Gaussian filter, I could not get it to converge again: > > https://gist.github.com/4afa874fccdb40e97cb8df0d20053547 > > If the algorithm is that sensitive to parameters, I'm sure there must have > been suggestions in literature on how to improve upon it. > > Best regards > St?fan > >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: original.jpg Type: image/jpeg Size: 32277 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: result_as_is.png Type: image/png Size: 11987 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: result_zoomed.png Type: image/png Size: 64328 bytes Desc: not available URL: From daniil.j.pakhomov at gmail.com Sun May 22 22:23:44 2016 From: daniil.j.pakhomov at gmail.com (Daniil Pakhomov) Date: Sun, 22 May 2016 19:23:44 -0700 (PDT) Subject: Difficulty making active contours work In-Reply-To: References: Message-ID: <052f1002-92c1-4f40-904f-2d3cacd7f2e2@googlegroups.com> It might be offtopic, but this seems like a good task for Conditional Random Fields(CRFs) which are usually used to improve initial coarse segmentation to a more finer one. There is a cython wrapper around a fast cpp implementation. Take a look at the examples folder with images: https://github.com/lucasb-eyer/pydensecrf ?????, 18 ??? 2016 ?., 4:09:34 UTC-4 ???????????? stefanv ???????: > > Hi everyone > > (And especially Emmanuelle) > > There was a recent StackOverflow question that I think can be addressed > well by active contours: > > > http://stackoverflow.com/questions/37234413/background-removal-masking-in-python-using-edge-detection-and-scikit-image > > I've tried to make our implementation work on these images, but to no > avail. Do you have any advice? My attempt is here: > > https://gist.github.com/e4313a0ecefb5ff37106b862e6cf25f5 > > (Note that I added a callback into the active contours loop: > > if callback is not None: > callback(np.array([x, y]).T) > > Perhaps this would be a useful addition in general?) > > Thanks! > St?fan > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jni.soma at gmail.com Sun May 22 23:12:18 2016 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Mon, 23 May 2016 13:12:18 +1000 Subject: Watershed segmentation problem In-Reply-To: <6ed8b8dd-2998-421c-951f-c1bbdf41bd8c@googlegroups.com> References: <6ed8b8dd-2998-421c-951f-c1bbdf41bd8c@googlegroups.com> Message-ID: The nonzero elements of your marker image should be numbered from 1 to n, rather than just being 1. You can use measure.label or ndimage.label for this. ? On 22 May 2016 at 1:59:58 AM, Jaime Lopez Carvajal (jalopcar at gmail.com) wrote: Hi, I want to get the watershed segmentation of remote sensing image (500 x 500 pixels) Following the @stefan-van-der-walt stackoverflow post (http://stackoverflow.com/questions/29573126/image-boundary-finding-and-filling), I can not get correct segmentation (see attached file) I am getting the coordinates images using >> coordinates = peak_local_max(image, min distance = 3), and then binarizing to have only 0 and 1 values. >> result = morphology.watershed(1 - distance_map, markers=marker_image) I use coordinates to get markers image. What could I am doing wrong? Any suggestion?? Thanks in advance, Jaime -- 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. To post to this group, send email to scikit-image at googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/6ed8b8dd-2998-421c-951f-c1bbdf41bd8c%40googlegroups.com. For more options, visit https://groups.google.com/d/optout. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jni.soma at gmail.com Sun May 22 23:30:04 2016 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Mon, 23 May 2016 13:30:04 +1000 Subject: Dropping support for 2.7 in 2020 In-Reply-To: References: <20160518064719.GA3031017@phare.normalesup.org> <20160518074002.GC3031017@phare.normalesup.org> <20160518175455.GA4080630@phare.normalesup.org> <20160520105049.GA3583487@phare.normalesup.org> <20160520141800.GD3583487@phare.normalesup.org> Message-ID: I would drop 2.7 sooner. NumPy/SciPy dropping it is the absolute cutoff, but there?s no reason why we can?t jump the gun (and lead rather than follow). Py2.7 users can make do with older releases. As St?fan mentioned, this is not about erasing Py2.7 support, but not releasing new features on Py2.7. Very different. I envision that we stop producing Py2.7 releases after 0.13, but we call that an ?LTS? release which will get bugfix backports until 2020. imho, with Py3.4 and especially Py3.5, Py3-only suddenly became very attractive. My three favourite features are type annotations, keyword-only arguments (these two together make it much easier to produce correct code and debug), and the @ matrix multiplication operator. The latter makes linear algebra code *so* *much* nicer to read and write, and we have our fair share in scikit-image. For my own projects, I am now Py3.5-only, always. Finally, as others have mentioned, but is worth restating: - Conda allows user-space installs of Python versions and packages, so you don?t ever depend on your sysadmin-controlled environment. - It is *absolutely false* that conda packages are only useful on Windows ? I have failed to compile scipy both on OSX and Ubuntu boxes. - It is also *not* a requirement to download the monolithic Anaconda distro ? with miniconda (which should be the default), you just install precisely what you need. - With conda-forge we now have a community-run repository of binary conda packages. So, in short, the switch to Py3 is easier than ever for *all* users, some might just not realise it yet ;), and switching to a Py3-only programming environment is a boon to all the scikit-image devs? though again some might not realise it yet ;). Juan. On 21 May 2016 at 12:20:38 PM, Nathaniel Smith (njs at vorpus.org) wrote: On May 20, 2016 07:30, "Michael Sarahan" wrote: > I don't think this is a concern for cython or scikit-image, but many people at bumping into the language support limit in the C++11 sense with Python 2.7 on Windows.? Since VS 2008 is the de-facto standard compiler for Python 2.7, people are unable to use C++11 code in modules for Python 2.7.? Some people use newer compilers anyway, which sometimes works, but is mixing runtimes, and can lead to bugs or crashes.? Many people would like to support Python 2.7 using a different compiler for the whole ecosystem.? One example is Ilastik, by folks at HHMI, using VS 2012 to have a custom stack:?https://github.com/ilastik/ilastik-build-conda I think getting mingwpy finished and polished is probably an easier solution for this problem than forking the entire py27-on-windows ecosystem :-) -n -- 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. To post to this group, send email to scikit-image at googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/CAPJVwB%3DjRQtHn9Xj0xwv3hxtDsjBvKYtJTB38ewBuZ84cNR4xw%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jni.soma at gmail.com Sun May 22 23:34:05 2016 From: jni.soma at gmail.com (Juan Nunez-Iglesias) Date: Mon, 23 May 2016 13:34:05 +1000 Subject: Thresholding a dark region in an image In-Reply-To: References: Message-ID: Hi Nabil, Have you looked at the skimage.filters.threshold_* functions? I would start by looking at the results from each of those on a few example sunspots to see whether one reliably gives you a reasonable result. Juan. On 20 May 2016 at 12:26:37 AM, Nabil Freij (nabil.freij at gmail.com) wrote: Hello, I have been investigating how to threshold a structure in my images. More specifically, a sunspot, that can be seen in Figure 1. The aim has been to isolate and measure the number of pixels that are part of the central part of a sunspot, which is the darkest region of the structure.? The method I have been using is to define a region which contains no features that are similar to a sunspot. The size of this region is not fixed but I generally make it as large as the data allows. This region is at the bottom black box in Figure 1 (ignore the slider). The mean and standard deviation of this region is calculated, which allows me to define a threshold limit, which is subtracting the standard deviation multiplied by a user defined constant from the mean. The constant is chosen so that overall, the threshold is selecting the pixels we know that are part of the central region. But this value varies depending the structure and the data source.? Another method I have discussed or looked into are related to Figure 2. On the left is a cropped field of view of the sunspot and on the right is a histogram of this image in red and in yellow is the histogram of the background box from Figure 1. By using the histogram, I can work out the numerical gradient and pick the points with the largest shift. I also tried this method on the original image by taking slices along the sunspot, however, due to the non-uniform nature of a sunspot the results were not very good. I was wondering if there were any suggestions to threshold this region that is not as ad hoc as my method? Thanks, Nabil -- 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. To post to this group, send email to scikit-image at googlegroups.com. To view this discussion on the web, visit https://groups.google.com/d/msgid/scikit-image/CADwJ0z1Sthz7OW8uu2G2i%2Bm9VaKPOEfnkuu%2BV70u-0Tjz75PMQ%40mail.gmail.com. For more options, visit https://groups.google.com/d/optout. -------------- next part -------------- An HTML attachment was scrubbed... URL: From anatole.chessel at polytechnique.edu Tue May 24 04:52:34 2016 From: anatole.chessel at polytechnique.edu (anatole.chessel at polytechnique.edu) Date: Tue, 24 May 2016 01:52:34 -0700 (PDT) Subject: Post-doc in bioimage informatics near Paris, France Message-ID: <0c38b276-ba60-4c79-88c1-bc5f96bc69cc@googlegroups.com> Dear all, My apologies for the spam, but we have an opening for a post-doc in (big) image analysis (in python, of course) which might be of interest... A 2 year post-doctoral position in bioimage informatics is available at the Laboratory of Optics and Bioscience (LOB) at Ecole polytechnique, Universit? Paris-Saclay in Palaiseau near Paris, France. The general aim is to adapt or develop image processing or analysis algorithms for large dataset alongside usable integrated pipelines, to allow acquired fluorescence microscopy data to be exploited for biological insight, with a particular application on large stitched confocal/multiphoton stacks for developmental neuroscience. More information in the pdf attached and available here: https://gargantua.polytechnique.fr/siatel-web/linkto/mICYYYU%28HjYK If you could forward this ad around you to people it can interest, I would be very grateful... Many thanks (And thanks to the list moderators for a prompt answer earlier) -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: PostDocBioimageInformaticsLOB0416.pdf Type: application/pdf Size: 54266 bytes Desc: not available URL: From fboulogne at sciunto.org Wed May 25 17:11:28 2016 From: fboulogne at sciunto.org (=?UTF-8?Q?Fran=c3=a7ois_Boulogne?=) Date: Wed, 25 May 2016 23:11:28 +0200 Subject: Thresholding a dark region in an image In-Reply-To: References: Message-ID: Hi, I'm actually working to add threshold algorithms to scikit-image. We are almost ready to merge the minimum algorithm (see https://github.com/scikit-image/scikit-image/pull/2104), Jeff made the implementation. I believe the histogram could be fruitful in your case and I think that you can study how this algorithm works and generalize it for 3 peaks in the histogram. Then, you will get two minima where you can threshold. Let us know if it works or not. You can probably cut your histogram "by hand" at one minimum to check if the result looks good or not. -- Fran?ois Boulogne. http://www.sciunto.org GPG: 32D5F22F From matteo.niccoli at gmail.com Thu May 26 11:11:55 2016 From: matteo.niccoli at gmail.com (Matteo) Date: Thu, 26 May 2016 08:11:55 -0700 (PDT) Subject: function to measure the (local) density of 1s in a binary image Message-ID: <1b36234e-79ed-4eec-9c4a-ea1b659069f3@googlegroups.com> Is there a function in scikit-image to calculate the the local density of 1s in a binary image? By local density of 1s I mean: 1) count the number of pixels that have value of 1 in a running/sliding window (preferrably circular but square would work too) 2) divide by the total number of pixels in the running window Thanks Matteo -------------- next part -------------- An HTML attachment was scrubbed... URL: From multicolor.mood at gmail.com Thu May 26 11:40:39 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Thu, 26 May 2016 08:40:39 -0700 (PDT) Subject: function to measure the (local) density of 1s in a binary image In-Reply-To: References: <1b36234e-79ed-4eec-9c4a-ea1b659069f3@googlegroups.com> Message-ID: By the way :), we do have such filter in `skimage`: http://scikit-image.org/docs/dev/api/skimage.filters.rank.html#mean , but it is selective to input dtype and doesn't support many boundary conditions' alternatives. Cheers, Egor ???????, 26 ??? 2016 ?., 18:29:59 UTC+3 ???????????? Egor Panfilov ???????: > > Hi Matteo! > > The function you're looking for is as simple as convolution [1] with a > typical structuring element [2] (we have square, circle and many more). I > suppose, this can also be called as 'mean filter': > > Here is an example: > >> import numpy as np >> import scipy.ndimage as ndi >> from skimage.morphology import square >> >> img = np.random.uniform(size=(5, 5)) >> img = (img > 0.5).astype(np.float) >> sem = square(3)/3**2 # Don't forget to normalize >> out = ndi.convolve(img, sem, mode='wrap') >> > > > print(img) >> print(sem) >> print(out) > > > Results to: > >> [[ 1. 0. 0. 1. 0.] >> [ 1. 0. 0. 0. 0.] >> [ 0. 0. 1. 1. 0.] >> [ 0. 0. 0. 0. 1.] >> [ 1. 0. 1. 0. 0.]] >> [[ 0.11111111 0.11111111 0.11111111] >> [ 0.11111111 0.11111111 0.11111111] >> [ 0.11111111 0.11111111 0.11111111]] >> [[ 0.33333333 0.44444444 0.22222222 0.22222222 0.44444444] >> [ 0.22222222 0.33333333 0.33333333 0.33333333 0.44444444] >> [ 0.22222222 0.22222222 0.22222222 0.33333333 0.33333333] >> [ 0.22222222 0.33333333 0.33333333 0.44444444 0.33333333] >> [ 0.33333333 0.33333333 0.22222222 0.33333333 0.44444444]] > > > Cheers, > Egor > > [1] > http://docs.scipy.org/doc/scipy/reference/generated/scipy.ndimage.convolve.html#scipy.ndimage.convolve > > [2] > http://scikit-image.org/docs/dev/api/skimage.morphology.html#module-skimage.morphology > > 2016-05-26 18:11 GMT+03:00 Matteo : > >> Is there a function in scikit-image to calculate the the local density of >> 1s in a binary image? >> >> By local density of 1s I mean: >> 1) count the number of pixels that have value of 1 in a running/sliding >> window (preferrably circular but square would work too) >> 2) divide by the total number of pixels in the running window >> >> Thanks >> 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. >> To post to this group, send email to scikit-image at googlegroups.com. >> To view this discussion on the web, visit >> https://groups.google.com/d/msgid/scikit-image/1b36234e-79ed-4eec-9c4a-ea1b659069f3%40googlegroups.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 Thu May 26 12:02:31 2016 From: matteo.niccoli at gmail.com (Matteo) Date: Thu, 26 May 2016 09:02:31 -0700 (PDT) Subject: function to measure the (local) density of 1s in a binary image In-Reply-To: References: <1b36234e-79ed-4eec-9c4a-ea1b659069f3@googlegroups.com> Message-ID: <07b425a1-4b8e-4e08-85a5-33bd3484efa2@googlegroups.com> Hi Egor For soem reason had not occurred to me to think of it as a mean filter. I like your ndimage + skimage solution, which will allow using circle, maybe I'll even try a diamond. Thanks a lot, Matteo On Thursday, May 26, 2016 at 9:40:40 AM UTC-6, Egor Panfilov wrote: > > By the way :), we do have such filter in `skimage`: > http://scikit-image.org/docs/dev/api/skimage.filters.rank.html#mean , but > it is selective to input dtype and doesn't support many boundary > conditions' alternatives. > > Cheers, > Egor > > ???????, 26 ??? 2016 ?., 18:29:59 UTC+3 ???????????? Egor Panfilov ???????: >> >> Hi Matteo! >> >> The function you're looking for is as simple as convolution [1] with a >> typical structuring element [2] (we have square, circle and many more). I >> suppose, this can also be called as 'mean filter': >> >> Here is an example: >> >>> import numpy as np >>> import scipy.ndimage as ndi >>> from skimage.morphology import square >>> >>> img = np.random.uniform(size=(5, 5)) >>> img = (img > 0.5).astype(np.float) >>> sem = square(3)/3**2 # Don't forget to normalize >>> out = ndi.convolve(img, sem, mode='wrap') >>> >> >> >> print(img) >>> print(sem) >>> print(out) >> >> >> Results to: >> >>> [[ 1. 0. 0. 1. 0.] >>> [ 1. 0. 0. 0. 0.] >>> [ 0. 0. 1. 1. 0.] >>> [ 0. 0. 0. 0. 1.] >>> [ 1. 0. 1. 0. 0.]] >>> [[ 0.11111111 0.11111111 0.11111111] >>> [ 0.11111111 0.11111111 0.11111111] >>> [ 0.11111111 0.11111111 0.11111111]] >>> [[ 0.33333333 0.44444444 0.22222222 0.22222222 0.44444444] >>> [ 0.22222222 0.33333333 0.33333333 0.33333333 0.44444444] >>> [ 0.22222222 0.22222222 0.22222222 0.33333333 0.33333333] >>> [ 0.22222222 0.33333333 0.33333333 0.44444444 0.33333333] >>> [ 0.33333333 0.33333333 0.22222222 0.33333333 0.44444444]] >> >> >> Cheers, >> Egor >> >> [1] >> http://docs.scipy.org/doc/scipy/reference/generated/scipy.ndimage.convolve.html#scipy.ndimage.convolve >> >> [2] >> http://scikit-image.org/docs/dev/api/skimage.morphology.html#module-skimage.morphology >> >> 2016-05-26 18:11 GMT+03:00 Matteo >: >> >>> Is there a function in scikit-image to calculate the the local density >>> of 1s in a binary image? >>> >>> By local density of 1s I mean: >>> 1) count the number of pixels that have value of 1 in a running/sliding >>> window (preferrably circular but square would work too) >>> 2) divide by the total number of pixels in the running window >>> >>> Thanks >>> 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 . >>> To post to this group, send email to scikit... at googlegroups.com >>> . >>> To view this discussion on the web, visit >>> https://groups.google.com/d/msgid/scikit-image/1b36234e-79ed-4eec-9c4a-ea1b659069f3%40googlegroups.com >>> >>> . >>> For more options, visit https://groups.google.com/d/optout. >>> >> >> -------------- next part -------------- An HTML attachment was scrubbed... URL: From multicolor.mood at gmail.com Thu May 26 11:29:57 2016 From: multicolor.mood at gmail.com (Egor Panfilov) Date: Thu, 26 May 2016 18:29:57 +0300 Subject: function to measure the (local) density of 1s in a binary image In-Reply-To: <1b36234e-79ed-4eec-9c4a-ea1b659069f3@googlegroups.com> References: <1b36234e-79ed-4eec-9c4a-ea1b659069f3@googlegroups.com> Message-ID: Hi Matteo! The function you're looking for is as simple as convolution [1] with a typical structuring element [2] (we have square, circle and many more). I suppose, this can also be called as 'mean filter': Here is an example: > import numpy as np > import scipy.ndimage as ndi > from skimage.morphology import square > > img = np.random.uniform(size=(5, 5)) > img = (img > 0.5).astype(np.float) > sem = square(3)/3**2 # Don't forget to normalize > out = ndi.convolve(img, sem, mode='wrap') > print(img) > print(sem) > print(out) Results to: > [[ 1. 0. 0. 1. 0.] > [ 1. 0. 0. 0. 0.] > [ 0. 0. 1. 1. 0.] > [ 0. 0. 0. 0. 1.] > [ 1. 0. 1. 0. 0.]] > [[ 0.11111111 0.11111111 0.11111111] > [ 0.11111111 0.11111111 0.11111111] > [ 0.11111111 0.11111111 0.11111111]] > [[ 0.33333333 0.44444444 0.22222222 0.22222222 0.44444444] > [ 0.22222222 0.33333333 0.33333333 0.33333333 0.44444444] > [ 0.22222222 0.22222222 0.22222222 0.33333333 0.33333333] > [ 0.22222222 0.33333333 0.33333333 0.44444444 0.33333333] > [ 0.33333333 0.33333333 0.22222222 0.33333333 0.44444444]] Cheers, Egor [1] http://docs.scipy.org/doc/scipy/reference/generated/scipy.ndimage.convolve.html#scipy.ndimage.convolve [2] http://scikit-image.org/docs/dev/api/skimage.morphology.html#module-skimage.morphology 2016-05-26 18:11 GMT+03:00 Matteo : > Is there a function in scikit-image to calculate the the local density of > 1s in a binary image? > > By local density of 1s I mean: > 1) count the number of pixels that have value of 1 in a running/sliding > window (preferrably circular but square would work too) > 2) divide by the total number of pixels in the running window > > Thanks > 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. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/1b36234e-79ed-4eec-9c4a-ea1b659069f3%40googlegroups.com > > . > For more options, visit https://groups.google.com/d/optout. > -------------- next part -------------- An HTML attachment was scrubbed... URL: From m.shrawankumar at gmail.com Fri May 27 15:33:54 2016 From: m.shrawankumar at gmail.com (Shrawan Kumar Mageswaran) Date: Fri, 27 May 2016 12:33:54 -0700 (PDT) Subject: Skimage - Getting the transformation from Geometric transformation object Message-ID: <647d6954-f208-44ca-ac75-ca31f9403e1d@googlegroups.com> Dear Skimage users/developers, I am trying to retrieve and store transformation parameters as a matrix after estimating them using the "skimage.transform.estimate_transform('Affine',src,dst)" method. I understand that the output of "skimage.transform.estimate_transform('Affine',src,dst)" is not a transformation matrix by itself (I do not know what the properties of such a transform object are and I would like to know more) and I would like to calculate the matrix from such an object. I would greatly appreciate your help on this issue. Thank you. Best, Shrawan -- Shrawan Kumar Mageswaran Post-doc Jensen Lab California Institute of Technology -------------- next part -------------- An HTML attachment was scrubbed... URL: From m.shrawankumar at gmail.com Fri May 27 18:50:06 2016 From: m.shrawankumar at gmail.com (Shrawan) Date: Fri, 27 May 2016 15:50:06 -0700 Subject: Skimage - Getting the transformation from Geometric transformation object In-Reply-To: References: <647d6954-f208-44ca-ac75-ca31f9403e1d@googlegroups.com> Message-ID: Thanks a ton, Dr. Walt! On Fri, May 27, 2016 at 1:38 PM, St?fan van der Walt wrote: > Hi Shrawan > > On Fri, 27 May 2016 at 12:33 Shrawan Kumar Mageswaran < > m.shrawankumar at gmail.com> wrote: > >> I am trying to retrieve and store transformation parameters as a matrix >> after estimating them using the >> "skimage.transform.estimate_transform('Affine',src,dst)" method. I >> understand that the output of >> "skimage.transform.estimate_transform('Affine',src,dst)" is not a >> transformation matrix by itself (I do not know what the properties of such >> a transform object are and I would like to know more) and I would like to >> calculate the matrix from such an object. I would greatly appreciate your >> help on this issue. Thank you. >> > > Take a look at the source here: > > > https://github.com/scikit-image/scikit-image/blob/master/skimage/transform/_geometric.py#L345 > > You are looking for the `params` attribute. > > St?fan > > -- > You received this message because you are subscribed to a topic in the > Google Groups "scikit-image" group. > To unsubscribe from this topic, visit > https://groups.google.com/d/topic/scikit-image/oKSPYsmF9rw/unsubscribe. > To unsubscribe from this group and all its topics, send an email to > scikit-image+unsubscribe at googlegroups.com. > To post to this group, send email to scikit-image at googlegroups.com. > To view this discussion on the web, visit > https://groups.google.com/d/msgid/scikit-image/CABDkGQ%3DY1CT1kd8qgWdUPXLi388Ezsqut-pXOYKWLiQzaUAwNg%40mail.gmail.com > > . > For more options, visit https://groups.google.com/d/optout. > -- Shrawan Kumar Mageswaran Postdoctoral Scholar Jensen Lab California Institute of Technology -------------- next part -------------- An HTML attachment was scrubbed... URL: From stefanv at berkeley.edu Fri May 27 16:38:03 2016 From: stefanv at berkeley.edu (=?UTF-8?Q?St=C3=A9fan_van_der_Walt?=) Date: Fri, 27 May 2016 20:38:03 +0000 Subject: Skimage - Getting the transformation from Geometric transformation object In-Reply-To: <647d6954-f208-44ca-ac75-ca31f9403e1d@googlegroups.com> References: <647d6954-f208-44ca-ac75-ca31f9403e1d@googlegroups.com> Message-ID: Hi Shrawan On Fri, 27 May 2016 at 12:33 Shrawan Kumar Mageswaran < m.shrawankumar at gmail.com> wrote: > I am trying to retrieve and store transformation parameters as a matrix > after estimating them using the > "skimage.transform.estimate_transform('Affine',src,dst)" method. I > understand that the output of > "skimage.transform.estimate_transform('Affine',src,dst)" is not a > transformation matrix by itself (I do not know what the properties of such > a transform object are and I would like to know more) and I would like to > calculate the matrix from such an object. I would greatly appreciate your > help on this issue. Thank you. > Take a look at the source here: https://github.com/scikit-image/scikit-image/blob/master/skimage/transform/_geometric.py#L345 You are looking for the `params` attribute. St?fan -------------- next part -------------- An HTML attachment was scrubbed... URL: From h.benoudjit at gmail.com Sun May 29 18:46:35 2016 From: h.benoudjit at gmail.com (Hakim Benoudjit) Date: Sun, 29 May 2016 15:46:35 -0700 (PDT) Subject: Genetic Algorithms based feature extraction algorithm (by minimizing a metric) Message-ID: Hello, Is there a pixel-based region growing algorithm implemented with Scikit-image that would be employed for feature extraction on an image? Basically, the kind of algorithms I'm looking for (or just checking if someone came across it, to see if I'm in the right direction) works by adding pixels to the detected feature based on the minimization of a certain metric. Potentially, a pixel can be removed if the metric is not optimized when this pixel is added. I'm thinking of implementing this feature extraction algorithm using Genetic Algorithms (GA), but I can't think of a way to make it possible to backtrack (i.e. remove a pixel). Anyone encountered something similar even if it's not using GAs? -------------- next part -------------- An HTML attachment was scrubbed... URL: