Had to track down one of my old professors.

Here is what we came up with

##This script is for use with rgb tuple files created through ImageJ.e +xe's xy coordinate extractor ##With RGB tuple files for each frame of a video, this script will ext +ract the RGB values for one pixel location. ##Each line of the new file has file name(= frame number), x, y, R, G, + B. $out_file="C:\\perl\\scripts\\bluetime.txt"; # out_file is the output file name, created by extracting the RGB valu +es from one coordinate unlink $out_file; # erased (deletes) the output file FIRST, otherwise it will continue t +o append to it! open ($output_file,">>",$out_file) or die "Could not open output_file! +!!"; #open file for append for ($i=1;$i<=60075;$i++) # files 00000.txt thru 60075.txt { $output_name = sprintf("%05d",$i); # first field in bluetime, 5 digits $input_file = sprintf("G:\\Frames_as_RGB_Tuples\\%05d.txt",$i); + # FQ input filename open ($infile, "<",$input_file) or die "Could not open input file +$input_file!!!"; ## "<" means read from, ">>" means append to, ">" means write to! # printf("G:\\Frames_as_RGB_Tuples\\%s.txt\n", $result); #For testing while(<$infile>) # read one line from infile, put in $_ { if($_ =~ /^390\t379/) #for each line, if "390(tab)379" is on the line then... { print $output_file sprintf("%s\t%s",$output_name,$_); #write to ouput_file #5 digits of filename plus the line where coordinate was f +ound } } close $infile; } close $output_file; ## by PK Birkmeyer and Ben Gregory one fine afternoon.

I would like if it gave me some feedback as to its progress, if anyone can help there.

This script worked, need help with next hurdle. Posted my pseudo code on this forum here.

http://www.perlmonks.org/?node_id=1072419


In reply to Re^2: need logic, police edited video by AwsedreswA
in thread need logic, police edited video by AwsedreswA

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.