<?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 on: Batch processing</title>
	<atom:link href="http://blogs.mathworks.com/steve/2006/06/06/batch-processing/feed/" rel="self" type="application/rss+xml" />
	<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/</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>By: Steve Eddins</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24801</link>
		<dc:creator>Steve Eddins</dc:creator>
		<pubDate>Wed, 18 Jan 2012 16:41:10 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24801</guid>
		<description>Bri&#8212;See the doc for &lt;a href=&quot;http://www.mathworks.com/help/techdoc/ref/xlswrite.html&quot; rel=&quot;nofollow&quot;&gt;xlswrite&lt;/a&gt;.</description>
		<content:encoded><![CDATA[<p>Bri&mdash;See the doc for <a href="http://www.mathworks.com/help/techdoc/ref/xlswrite.html" rel="nofollow">xlswrite</a>.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bri</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24800</link>
		<dc:creator>Bri</dc:creator>
		<pubDate>Wed, 18 Jan 2012 16:27:32 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24800</guid>
		<description>Hi Steve,

I was wondering if you please make a suggestion for a couple of tweaks for the initial posting of the code you have here:

1) Output the file name for each file that was processed to an external source such as a spreadsheet. (I&#039;m trying to generate some sort of a tracking method for the batches of images that are being processed.)

2) Generate a measurement for each corresponding file entry (say, something like area, from regionprops), to be output to the same spreadsheet.

Thank you very much and have a good one.

Cheers</description>
		<content:encoded><![CDATA[<p>Hi Steve,</p>
<p>I was wondering if you please make a suggestion for a couple of tweaks for the initial posting of the code you have here:</p>
<p>1) Output the file name for each file that was processed to an external source such as a spreadsheet. (I&#8217;m trying to generate some sort of a tracking method for the batches of images that are being processed.)</p>
<p>2) Generate a measurement for each corresponding file entry (say, something like area, from regionprops), to be output to the same spreadsheet.</p>
<p>Thank you very much and have a good one.</p>
<p>Cheers</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve Eddins</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24787</link>
		<dc:creator>Steve Eddins</dc:creator>
		<pubDate>Tue, 10 Jan 2012 14:02:06 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24787</guid>
		<description>Ponsuresh&#8212;You need to call dir:

&lt;pre class=&quot;code&quot;&gt;
path1=dir(&#039;F:\DICOMs\Subject1\*.dcm&#039;);
&lt;/pre&gt;</description>
		<content:encoded><![CDATA[<p>Ponsuresh&mdash;You need to call dir:</p>
<pre class="code">
path1=dir('F:\DICOMs\Subject1\*.dcm');
</pre>
]]></content:encoded>
	</item>
	<item>
		<title>By: Vlad</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24786</link>
		<dc:creator>Vlad</dc:creator>
		<pubDate>Tue, 10 Jan 2012 12:42:32 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24786</guid>
		<description>I know this is not MATLAB way, but if you are in Linux/Mac, then with ImageMagick package this is as simple as:

ls *.jpg &#124; convert -resize 640x480

or if you want to leverage all your 4 cores:

find . -name *.jpg &#124; xargs convert -resize 640x480</description>
		<content:encoded><![CDATA[<p>I know this is not MATLAB way, but if you are in Linux/Mac, then with ImageMagick package this is as simple as:</p>
<p>ls *.jpg | convert -resize 640&#215;480</p>
<p>or if you want to leverage all your 4 cores:</p>
<p>find . -name *.jpg | xargs convert -resize 640&#215;480</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ponsuresh</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24785</link>
		<dc:creator>Ponsuresh</dc:creator>
		<pubDate>Tue, 10 Jan 2012 05:29:28 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24785</guid>
		<description>Hai Steve, please help me to fix this code.I am trying to read the DICOM files stored in the folder &quot;F:/DICOMs/Subject1&quot; using this code.


function displaydir(path1)
 path1=&#039;F:\DICOMs\Subject1\*.dcm&#039;;
 nooffiles=numel(path1);
  for k=1:nooffiles
    path1(k).name;         I=dicomread(fullfile(&#039;F:\DICOMs\Subject1&#039;),path1(k).name);
    imshow(I,[]);
    pause;
 end


But, i am getting the error,

??? Improper index matrix reference.

Error in ==&gt; displaydir at 10
    path1(k).name; 

Please help me to solve this problem.....Thanks in advance Steve.....</description>
		<content:encoded><![CDATA[<p>Hai Steve, please help me to fix this code.I am trying to read the DICOM files stored in the folder &#8220;F:/DICOMs/Subject1&#8243; using this code.</p>
<p>function displaydir(path1)<br />
 path1=&#8217;F:\DICOMs\Subject1\*.dcm&#8217;;<br />
 nooffiles=numel(path1);<br />
  for k=1:nooffiles<br />
    path1(k).name;         I=dicomread(fullfile(&#8216;F:\DICOMs\Subject1&#8242;),path1(k).name);<br />
    imshow(I,[]);<br />
    pause;<br />
 end</p>
<p>But, i am getting the error,</p>
<p>??? Improper index matrix reference.</p>
<p>Error in ==&gt; displaydir at 10<br />
    path1(k).name; </p>
<p>Please help me to solve this problem&#8230;..Thanks in advance Steve&#8230;..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve Eddins</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24767</link>
		<dc:creator>Steve Eddins</dc:creator>
		<pubDate>Thu, 29 Dec 2011 13:33:18 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24767</guid>
		<description>Tamara and Asadullah&#8212;See my &lt;a href=&quot;http://blogs.mathworks.com/steve/2011/12/23/batch-processing-files-in-another-folder/&quot; rel=&quot;nofollow&quot;&gt;23-Dec-2011 post&lt;/a&gt;.</description>
		<content:encoded><![CDATA[<p>Tamara and Asadullah&mdash;See my <a href="http://blogs.mathworks.com/steve/2011/12/23/batch-processing-files-in-another-folder/" rel="nofollow">23-Dec-2011 post</a>.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Asadullah</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24749</link>
		<dc:creator>Asadullah</dc:creator>
		<pubDate>Fri, 16 Dec 2011 18:27:55 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24749</guid>
		<description>Hi Steve,
i am trying to process some images by following the MATLAB demo. after getting the names of files when i try to see any of the files then its gives the error. the detail is asfollows:

&lt;pre class=&quot;code&quot;&gt;
&gt;&gt; fileFolder = fullfile(matlabroot,&#039;work&#039;,&#039;original&#039;);
dirOutput = dir(fullfile(fileFolder,&#039;AT3_1m4_*.jpg&#039;));
&gt;&gt; fileNames = {dirOutput.name}&#039;

fileNames = 

    &#039;AT3_1m4_001.jpg&#039;
    &#039;AT3_1m4_002.jpg&#039;
    &#039;AT3_1m4_003.jpg&#039;
    &#039;AT3_1m4_004.jpg&#039;
    &#039;AT3_1m4_005.jpg&#039;
    &#039;AT3_1m4_006.jpg&#039;
    &#039;AT3_1m4_007.jpg&#039;

    [...]

    &#039;AT3_1m4_116.jpg&#039;
    &#039;AT3_1m4_117.jpg&#039;
    &#039;AT3_1m4_118.jpg&#039;
    &#039;AT3_1m4_119.jpg&#039;
    &#039;AT3_1m4_120.jpg&#039;

&gt;&gt; I=imread(fileNames{1});
??? Error using ==&gt; imread
File &quot;AT3_1m4_001.jpg&quot; does not exist.
&lt;/pre&gt;

I could not understand where is the problem? please help me to solve this.

Thanks a lot</description>
		<content:encoded><![CDATA[<p>Hi Steve,<br />
i am trying to process some images by following the MATLAB demo. after getting the names of files when i try to see any of the files then its gives the error. the detail is asfollows:</p>
<pre class="code">
&gt;&gt; fileFolder = fullfile(matlabroot,'work','original');
dirOutput = dir(fullfile(fileFolder,'AT3_1m4_*.jpg'));
&gt;&gt; fileNames = {dirOutput.name}'

fileNames = 

    'AT3_1m4_001.jpg'
    'AT3_1m4_002.jpg'
    'AT3_1m4_003.jpg'
    'AT3_1m4_004.jpg'
    'AT3_1m4_005.jpg'
    'AT3_1m4_006.jpg'
    'AT3_1m4_007.jpg'

    [...]

    'AT3_1m4_116.jpg'
    'AT3_1m4_117.jpg'
    'AT3_1m4_118.jpg'
    'AT3_1m4_119.jpg'
    'AT3_1m4_120.jpg'

&gt;&gt; I=imread(fileNames{1});
??? Error using ==&gt; imread
File "AT3_1m4_001.jpg" does not exist.
</pre>
<p>I could not understand where is the problem? please help me to solve this.</p>
<p>Thanks a lot</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Tamara</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24638</link>
		<dc:creator>Tamara</dc:creator>
		<pubDate>Tue, 15 Nov 2011 04:19:13 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24638</guid>
		<description>Hi there: I&#039;m trying to write a script that will take all jpg files from a folder specified by the user and rotate them by -90 degrees before putting them ideally in a new folder also specified by the user. My code looks like this:

d = uigetdir(&#039;/Users/myname/Documents/MATLAB&#039;, &#039;Pick the directory to get .jpg files&#039;); %Get input directory
files = dir(fullfile(d,&#039;*.jpg&#039;)); % Only take .jpg files
 for k = 1:numel(files); % For all of the elements in the specified directory
     rotatedpics = imread(files(k).name);% read the pictures in
     rotatedpics = imrotate(files, -90); % rotate the pictures
     imwrite(rotatedpics, [&#039;rotated/&#039; files(k).name]); %and write the pictures into another specified director   
 end

As soon as I try to run I get an error that my file &quot;1.jpg&quot; does not exist! 

Any help would be appreciated; I&#039;m a complete MATLAB novice :)</description>
		<content:encoded><![CDATA[<p>Hi there: I&#8217;m trying to write a script that will take all jpg files from a folder specified by the user and rotate them by -90 degrees before putting them ideally in a new folder also specified by the user. My code looks like this:</p>
<p>d = uigetdir(&#8216;/Users/myname/Documents/MATLAB&#8217;, &#8216;Pick the directory to get .jpg files&#8217;); %Get input directory<br />
files = dir(fullfile(d,&#8217;*.jpg&#8217;)); % Only take .jpg files<br />
 for k = 1:numel(files); % For all of the elements in the specified directory<br />
     rotatedpics = imread(files(k).name);% read the pictures in<br />
     rotatedpics = imrotate(files, -90); % rotate the pictures<br />
     imwrite(rotatedpics, ['rotated/' files(k).name]); %and write the pictures into another specified director<br />
 end</p>
<p>As soon as I try to run I get an error that my file &#8220;1.jpg&#8221; does not exist! </p>
<p>Any help would be appreciated; I&#8217;m a complete MATLAB novice :)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rodney</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24631</link>
		<dc:creator>rodney</dc:creator>
		<pubDate>Mon, 14 Nov 2011 04:52:07 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24631</guid>
		<description>hai steve,i think i got the solution.basically this is what u taught to  Haseeb.Thanks steve


image=dir(&#039;*&#039;);
for k=1:numel(image)
if ~image(k) .isdir &amp;&amp; isdicom(image(k) .name)  % i think here is the problem,as it dont have the right extension
metadata=dicominfo (image(k) .name);
ans=metadata
end
end</description>
		<content:encoded><![CDATA[<p>hai steve,i think i got the solution.basically this is what u taught to  Haseeb.Thanks steve</p>
<p>image=dir(&#8216;*&#8217;);<br />
for k=1:numel(image)<br />
if ~image(k) .isdir &amp;&amp; isdicom(image(k) .name)  % i think here is the problem,as it dont have the right extension<br />
metadata=dicominfo (image(k) .name);<br />
ans=metadata<br />
end<br />
end</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: rodney</title>
		<link>http://blogs.mathworks.com/steve/2006/06/06/batch-processing/#comment-24613</link>
		<dc:creator>rodney</dc:creator>
		<pubDate>Wed, 09 Nov 2011 06:32:17 +0000</pubDate>
		<guid isPermaLink="false">http://blogs.mathworks.com/steve/?p=61#comment-24613</guid>
		<description>Hai Steve,thanks for your feedback,maybe i need to try diffrent method.</description>
		<content:encoded><![CDATA[<p>Hai Steve,thanks for your feedback,maybe i need to try diffrent method.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

