Ok. I understand.<br><br><div class="gmail_quote">On Sun, Mar 27, 2011 at 8:13 PM, Mihael Hategan <span dir="ltr"><<a href="mailto:hategan@mcs.anl.gov">hategan@mcs.anl.gov</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
Let me be clear. I don't think that's your problem. That is simply a<br>
matter of, perhaps, style. I found it unclear. It doesn't say what it<br>
does.<br>
<div><div></div><div class="h5"><br>
On Sun, 2011-03-27 at 20:10 -0500, Jonathan Monette wrote:<br>
> This makes sense syntactically but I am guessing the internal logic<br>
> does not like this so is this something that Swift shouldn't do or<br>
> something that Swift should do but is just broken?<br>
><br>
> On Sun, Mar 27, 2011 at 8:05 PM, Jonathan Monette<br>
> <<a href="mailto:jon.monette@gmail.com">jon.monette@gmail.com</a>> wrote:<br>
> Yea. I use the foreach loop because I need to iterate through<br>
> the diff_imgs array and run an app on each of the entries.<br>
> The loop runs and completes and all the files in stats are<br>
> mapped and have data they are just not being closed. So is<br>
> there a better way of accomplishing what I am doing in Swift?<br>
><br>
><br>
><br>
><br>
> On Sun, Mar 27, 2011 at 8:02 PM, Daniel S. Katz<br>
> <<a href="mailto:dsk@ci.uchicago.edu">dsk@ci.uchicago.edu</a>> wrote:<br>
> Can you suggest how this should be done?<br>
><br>
> Dan<br>
><br>
><br>
><br>
> On Mar 27, 2011, at 8:00 PM, Mihael Hategan wrote:<br>
><br>
> > Well, you seem to be iterating over an array that<br>
> you are trying to<br>
> > build inside the iteration, and you are not doing a<br>
> fold. It's somewhat<br>
> > coincidental that it works, probably because stats<br>
> is mapped by a static<br>
> > mapper and you don't actually use the value ("img").<br>
> ><br>
> > Though I see what you are trying to do. And it<br>
> should either work or<br>
> > fail nicely. So I'll see if I can make a simple test<br>
> case out of this.<br>
> ><br>
> > Mihael<br>
> ><br>
> > On Sun, 2011-03-27 at 19:43 -0500, Jonathan Monette<br>
> wrote:<br>
> >> stats is an array mapped to several files in a<br>
> directory of metadata<br>
> >> generated by mFitplane. I need to pass all these<br>
> files and another<br>
> >> metadata file to mConcatFit which is the app after<br>
> this foreach loop.<br>
> >> I need to wait for the foreach loop to be complete<br>
> before mConcatFit<br>
> >> can run.<br>
> >><br>
> >> On Sun, Mar 27, 2011 at 7:41 PM, Mihael Hategan<br>
> <<a href="mailto:hategan@mcs.anl.gov">hategan@mcs.anl.gov</a>><br>
> >> wrote:<br>
> >> You have:<br>
> >> foreach img, i in stats<br>
> >> {<br>
> >> stats[ i ] = mFitplane<br>
> ( diff_imgs[i] );<br>
> >> }<br>
> >><br>
> >><br>
> >> What is it that you are trying to do there?<br>
> >><br>
> >> Mihael<br>
> >><br>
> >><br>
> >> On Sun, 2011-03-27 at 15:54 -0500, Jonathan<br>
> Monette wrote:<br>
> >>> here is my entire script<br>
> >>><br>
> >>> On Sun, Mar 27, 2011 at 3:45 PM, Mihael Hategan<br>
> >> <<a href="mailto:hategan@mcs.anl.gov">hategan@mcs.anl.gov</a>><br>
> >>> wrote:<br>
> >>> On Wed, 2011-03-23 at 16:31 -0500, Jonathan<br>
> Monette<br>
> >> wrote:<br>
> >>><br>
> >>>> How can the array be closed but all of its values<br>
> >> not be?<br>
> >>><br>
> >>><br>
> >>> The array being closed simply means that<br>
> its size is<br>
> >> known,<br>
> >>> but not<br>
> >>> necessarily that its elements have all been<br>
> >> computed.<br>
> >>><br>
> >>> I'll look at the log, but I'd also like the<br>
> entire<br>
> >> script.<br>
> >>><br>
> >>> Mihael<br>
> >>><br>
> >>><br>
> >>><br>
> >>><br>
> >>><br>
> >>> --<br>
> >>> Any intelligent fool can make things bigger and<br>
> more<br>
> >> complex... It<br>
> >>> takes a touch of genius - and a lot of courage to<br>
> move in<br>
> >> the opposite<br>
> >>> direction.<br>
> >>> - Albert Einstein<br>
> >>><br>
> >>><br>
> >><br>
> >><br>
> >><br>
> >><br>
> >><br>
> >><br>
> >> --<br>
> >> Any intelligent fool can make things bigger and<br>
> more complex... It<br>
> >> takes a touch of genius - and a lot of courage to<br>
> move in the opposite<br>
> >> direction.<br>
> >> - Albert Einstein<br>
> >><br>
> >><br>
> ><br>
> ><br>
><br>
> > _______________________________________________<br>
> > Swift-devel mailing list<br>
> > <a href="mailto:Swift-devel@ci.uchicago.edu">Swift-devel@ci.uchicago.edu</a><br>
> ><br>
> <a href="http://mail.ci.uchicago.edu/mailman/listinfo/swift-devel" target="_blank">http://mail.ci.uchicago.edu/mailman/listinfo/swift-devel</a><br>
><br>
> --<br>
> Daniel S. Katz<br>
> University of Chicago<br>
> <a href="tel:%28773%29%20834-7186">(773) 834-7186</a> (voice)<br>
> <a href="tel:%28773%29%20834-3700">(773) 834-3700</a> (fax)<br>
> <a href="mailto:d.katz@ieee.org">d.katz@ieee.org</a> or <a href="mailto:dsk@ci.uchicago.edu">dsk@ci.uchicago.edu</a><br>
> <a href="http://www.ci.uchicago.edu/~dsk/" target="_blank">http://www.ci.uchicago.edu/~dsk/</a><br>
><br>
><br>
><br>
><br>
><br>
><br>
><br>
> --<br>
><br>
> Any intelligent fool can make things bigger and more<br>
> complex... It takes a touch of genius - and a lot of courage<br>
> to move in the opposite direction.<br>
> - Albert Einstein<br>
><br>
><br>
><br>
><br>
><br>
><br>
> --<br>
> Any intelligent fool can make things bigger and more complex... It<br>
> takes a touch of genius - and a lot of courage to move in the opposite<br>
> direction.<br>
> - Albert Einstein<br>
><br>
><br>
<br>
<br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Any intelligent fool can make things bigger and more complex... It takes a touch of genius - and a lot of courage to move in the opposite direction.<br>- Albert Einstein<br>
<br><br>