<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments for Steve on Image Processing</title>
	<atom:link href="http://blogs.mathworks.com/steve/comments/feed/" rel="self" type="application/rss+xml" />
	<link>http://blogs.mathworks.com/steve</link>
	<description>Steve Eddins manages the Image &#38; Geospatial development team at The MathWorks and coauthored Digital Image Processing Using MATLAB. He writes here about image processing concepts, algorithm implementations, and MATLAB.</description>
	<lastBuildDate>Wed, 01 Feb 2012 13:58:45 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>Comment on Consider multibandread for reading your data by Giulia</title>
		<link>http://blogs.mathworks.com/steve/2009/02/06/consider-multibandread-for-reading-your-data/#comment-24825</link>
		<dc:creator>Giulia</dc:creator>
		<pubDate>Wed, 01 Feb 2012 13:58:45 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2009/02/06/consider-multibandread-for-reading-your-data/#comment-24825</guid>
		<description>sorry..

fread(fid,(1:(rows*cols*bands)),&#039;double&#039;,&#039;ieee-le&#039;);
..
im4 = multibandread(&#039;prova.raw&#039;, [441 476 160], ...
                    &#039;double&#039;, 0, &#039;bsq&#039;, &#039;ieee-le&#039;, ...
                    {&#039;Band&#039;, &#039;Direct&#039;} );
imshow(im4);
</description>
		<content:encoded><![CDATA[<p>sorry..</p>
<p>fread(fid,(1:(rows*cols*bands)),&#8217;double&#8217;,'ieee-le&#8217;);<br />
..<br />
im4 = multibandread(&#8216;prova.raw&#8217;, [441 476 160], &#8230;<br />
                    &#8216;double&#8217;, 0, &#8216;bsq&#8217;, &#8216;ieee-le&#8217;, &#8230;<br />
                    {&#8216;Band&#8217;, &#8216;Direct&#8217;} );<br />
imshow(im4);</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Consider multibandread for reading your data by Giulia</title>
		<link>http://blogs.mathworks.com/steve/2009/02/06/consider-multibandread-for-reading-your-data/#comment-24824</link>
		<dc:creator>Giulia</dc:creator>
		<pubDate>Wed, 01 Feb 2012 13:55:44 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2009/02/06/consider-multibandread-for-reading-your-data/#comment-24824</guid>
		<description>Hi!I&#039;m using multibandread function for reading raw image.I followed mathworks examples: defined my dataset, instead of using fwrite, I used: 
...
 
but i&#039;ve some problems on fread: Invalid size. Thanks in advance</description>
		<content:encoded><![CDATA[<p>Hi!I&#8217;m using multibandread function for reading raw image.I followed mathworks examples: defined my dataset, instead of using fwrite, I used:<br />
&#8230;</p>
<p>but i&#8217;ve some problems on fread: Invalid size. Thanks in advance</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Connected component labeling &#8211; Part 5 by max</title>
		<link>http://blogs.mathworks.com/steve/2007/05/11/connected-component-labeling-part-5/#comment-24822</link>
		<dc:creator>max</dc:creator>
		<pubDate>Tue, 31 Jan 2012 20:22:06 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2007/05/11/connected-component-labeling-part-5/#comment-24822</guid>
		<description>Is there any idea to do labeling the non-binary image. 
Thank you in advance. :)</description>
		<content:encoded><![CDATA[<p>Is there any idea to do labeling the non-binary image.<br />
Thank you in advance. :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on MATLAB R2009a &#8211; imread and multipage TIFFs by Grant</title>
		<link>http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24820</link>
		<dc:creator>Grant</dc:creator>
		<pubDate>Mon, 30 Jan 2012 20:01:21 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24820</guid>
		<description>Thanks- Don&#039;t know how I missed that.. I think I searched for &quot;can&#039;t open file for writing,&quot; the output from 2010a, while these posts refer to &quot;couldn&#039;t open file for writing.&quot;</description>
		<content:encoded><![CDATA[<p>Thanks- Don&#8217;t know how I missed that.. I think I searched for &#8220;can&#8217;t open file for writing,&#8221; the output from 2010a, while these posts refer to &#8220;couldn&#8217;t open file for writing.&#8221;</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Generating Hilbert curves by strange attractor</title>
		<link>http://blogs.mathworks.com/steve/2012/01/25/generating-hilbert-curves/#comment-24819</link>
		<dc:creator>strange attractor</dc:creator>
		<pubDate>Mon, 30 Jan 2012 18:15:58 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=444#comment-24819</guid>
		<description>This topic is closely related to maze generation algorithms. If you are interested here is a Wiki link:
http://en.wikipedia.org/wiki/Maze_generation_algorithm</description>
		<content:encoded><![CDATA[<p>This topic is closely related to maze generation algorithms. If you are interested here is a Wiki link:<br />
<a href="http://en.wikipedia.org/wiki/Maze_generation_algorithm" rel="nofollow">http://en.wikipedia.org/wiki/Maze_generation_algorithm</a></p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on MATLAB R2009a &#8211; imread and multipage TIFFs by Steve Eddins</title>
		<link>http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24818</link>
		<dc:creator>Steve Eddins</dc:creator>
		<pubDate>Mon, 30 Jan 2012 17:44:51 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24818</guid>
		<description>Grant&#8212;See my &lt;a href=&quot;http://blogs.mathworks.com/steve/2010/11/09/the-mystery-of-the-failing-tiff-append-loop/&quot; rel=&quot;nofollow&quot;&gt;09-Nov-2010 blog post&lt;/a&gt; and &lt;a href=&quot;http://www.mathworks.com/support/solutions/en/data/1-DQPRHC/index.html?solution=1-DQPRHC&quot; rel=&quot;nofollow&quot;&gt;this tech support solution&lt;/a&gt;.</description>
		<content:encoded><![CDATA[<p>Grant&mdash;See my <a href="http://blogs.mathworks.com/steve/2010/11/09/the-mystery-of-the-failing-tiff-append-loop/" rel="nofollow">09-Nov-2010 blog post</a> and <a href="http://www.mathworks.com/support/solutions/en/data/1-DQPRHC/index.html?solution=1-DQPRHC" rel="nofollow">this tech support solution</a>.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on MATLAB R2009a &#8211; imread and multipage TIFFs by Grant</title>
		<link>http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24817</link>
		<dc:creator>Grant</dc:creator>
		<pubDate>Mon, 30 Jan 2012 17:31:41 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/2009/04/02/matlab-r2009a-imread-and-multipage-tiffs/#comment-24817</guid>
		<description>Hello again,

For quite some time I have been successfully using a code that invokes imwrite in a loop.  The specific command is

imwrite(A,outfile,&#039;tif&#039;,&#039;Compression&#039;,&#039;none&#039;,&#039;WriteMode&#039;,&#039;append&#039;);

Suddenly I&#039;m getting the following error in the middle of the writing process, seemingly at random (random file it crashes on, and in random spots in the stack):

??? Error using ==&gt; imwrite at 453
Can&#039;t open file &quot;I:\Grant\PIFE\120129\rot_RT2_100nM_RT_5.tif &quot; for writing.
You may not have write permission.

Error in ==&gt; tiffdir at 170
          imwrite(A,outfile,&#039;tif&#039;,&#039;Compression&#039;,&#039;none&#039;,&#039;WriteMode&#039;,&#039;append&#039;);

Many times I can just restart the program and it will go without a hitch, however this is not desirable as I typically process large batches of large files overnight... 

Any suggestions?</description>
		<content:encoded><![CDATA[<p>Hello again,</p>
<p>For quite some time I have been successfully using a code that invokes imwrite in a loop.  The specific command is</p>
<p>imwrite(A,outfile,&#8217;tif&#8217;,'Compression&#8217;,'none&#8217;,'WriteMode&#8217;,'append&#8217;);</p>
<p>Suddenly I&#8217;m getting the following error in the middle of the writing process, seemingly at random (random file it crashes on, and in random spots in the stack):</p>
<p>??? Error using ==&gt; imwrite at 453<br />
Can&#8217;t open file &#8220;I:\Grant\PIFE\120129\rot_RT2_100nM_RT_5.tif &#8221; for writing.<br />
You may not have write permission.</p>
<p>Error in ==&gt; tiffdir at 170<br />
          imwrite(A,outfile,&#8217;tif&#8217;,'Compression&#8217;,'none&#8217;,'WriteMode&#8217;,'append&#8217;);</p>
<p>Many times I can just restart the program and it will go without a hitch, however this is not desirable as I typically process large batches of large files overnight&#8230; </p>
<p>Any suggestions?</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Exploring shortest paths &#8211; part 3 by Steve Eddins</title>
		<link>http://blogs.mathworks.com/steve/2011/12/02/exploring-shortest-paths-part-3/#comment-24816</link>
		<dc:creator>Steve Eddins</dc:creator>
		<pubDate>Mon, 30 Jan 2012 13:17:28 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=397#comment-24816</guid>
		<description>Ken&#8212;I don&#039;t agree. Relative tolerance tests (like your suggestions) and absolute tolerances (like I used in this post) both have their places, and this is an appropriate use of an absolute tolerance test. I need to distinguish between a distance value corresponding to the shortest path and a distance corresponding to a path that is one step longer. The difference in distances could be 2.0 - sqrt(2). So really I could have gotten away with a much higher tolerance than I used above. However, it is not appropriate to scale the tolerance even higher according to the magnitude of D. Besides, the geodesic distance algorithm works by incremental additions of 1.0 or sqrt(2.0), so if the distances were huge enough to cause the comparison failure you are worried about, the distance transform step itself would have failed. But since single precision is good enough to handle distance transform computations for something like a 5 million x 5 million image (200 terabytes or so), I don&#039;t think it&#039;s worth worrying about.</description>
		<content:encoded><![CDATA[<p>Ken&mdash;I don&#8217;t agree. Relative tolerance tests (like your suggestions) and absolute tolerances (like I used in this post) both have their places, and this is an appropriate use of an absolute tolerance test. I need to distinguish between a distance value corresponding to the shortest path and a distance corresponding to a path that is one step longer. The difference in distances could be 2.0 &#8211; sqrt(2). So really I could have gotten away with a much higher tolerance than I used above. However, it is not appropriate to scale the tolerance even higher according to the magnitude of D. Besides, the geodesic distance algorithm works by incremental additions of 1.0 or sqrt(2.0), so if the distances were huge enough to cause the comparison failure you are worried about, the distance transform step itself would have failed. But since single precision is good enough to handle distance transform computations for something like a 5 million x 5 million image (200 terabytes or so), I don&#8217;t think it&#8217;s worth worrying about.</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Exploring shortest paths &#8211; part 3 by ken stanley</title>
		<link>http://blogs.mathworks.com/steve/2011/12/02/exploring-shortest-paths-part-3/#comment-24815</link>
		<dc:creator>ken stanley</dc:creator>
		<pubDate>Sat, 28 Jan 2012 16:47:13 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=397#comment-24815</guid>
		<description>This technique will work most of the time, but will occasionally fail.  The basic issue is that a == b is only true if a is identical to b down to the last bit.  round(a*32)/32 == round(b*32)/32 will be true for most values of a and b that are close.  It fails however, for a=1/64 - 0.0000001 and b = 1/64;  round(a*32)/32 = 0 whereas round(b*32)/32 = 0.03125 (i.e. 1/32).

Hence, you have replaced a bug which will happen fairly often with a bug that will happen only when you least expect it.  If you are using single precision, this will happen more than one time in a million.  In double precision the odds are much longer and perhaps acceptable to most people.  

The following untested code should be more robust:

D = ( D - min(D(:)) ) / max(D(:)) 
D ( D &lt; .00001 ) = 0 
</description>
		<content:encoded><![CDATA[<p>This technique will work most of the time, but will occasionally fail.  The basic issue is that a == b is only true if a is identical to b down to the last bit.  round(a*32)/32 == round(b*32)/32 will be true for most values of a and b that are close.  It fails however, for a=1/64 &#8211; 0.0000001 and b = 1/64;  round(a*32)/32 = 0 whereas round(b*32)/32 = 0.03125 (i.e. 1/32).</p>
<p>Hence, you have replaced a bug which will happen fairly often with a bug that will happen only when you least expect it.  If you are using single precision, this will happen more than one time in a million.  In double precision the odds are much longer and perhaps acceptable to most people.  </p>
<p>The following untested code should be more robust:</p>
<p>D = ( D &#8211; min(D(:)) ) / max(D(:))<br />
D ( D &lt; .00001 ) = 0</p>
]]></content:encoded>
	</item>
	<item>
		<title>Comment on Generating Hilbert curves by David Talbot</title>
		<link>http://blogs.mathworks.com/steve/2012/01/25/generating-hilbert-curves/#comment-24814</link>
		<dc:creator>David Talbot</dc:creator>
		<pubDate>Fri, 27 Jan 2012 12:36:15 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=444#comment-24814</guid>
		<description>Could these curves be used to create window defrosters - that leave advertising or patterns?</description>
		<content:encoded><![CDATA[<p>Could these curves be used to create window defrosters &#8211; that leave advertising or patterns?</p>
]]></content:encoded>
	</item>
</channel>
</rss>

