How to extract the red layer from BayerRG8 file with VBAI?

Dear readers,
We're currentely trying to build a inspection program using a CVS and two cameras.
A first question to help us: How can we extract the red layer from a Bayer RG8 image?
To illustrate a lit bit more: lets take a picture of chilis and tomatoes plants. We would like to extract the red color of the picture to know where the vegetable are and if they are eatable.
So, in a first time, we just want to see the red layer of the picture.
On a second step, we would like to extract the poistion of the red areas and rank them according to intensities and store all the relevant data in a .txt file.
Thank in advance for the time you will spend on that topic.
Regards

Maybe including a picture with the info you want would help. It sounds like you could use a detect object step (which works with color images), and you could get the position of all red objects. I would also recommend using the Hue plane instead of the Red plane to look for color since this is more robust to lighting changes. Once you have the bounding box for each red object, you can create a programmatic ROI around it and use the Measure Color step to get detailed color information about your reb objects. Here's a sample inspection that uses colored candy to give you an example of what I'm suggesting. Let us know if more specifically what you are looking for if this doesn't help. The example is in VBAI 2012. Let us know what version of VBAI you are using because this may affect what functionality you can use.
Thanks,
Brad
Attachments:
Color Example.zip ‏358 KB

Similar Messages

  • How to Extract the Highlight Text in PDF File

    Hi Scripters,
    i want know, how to extract the hightlight text in pdf files for text only format for (*.txt) file extension save.
    regards
    baby

    Hi,
    Okay i'll try do best.
    thanks for your reply.
    Regards
    Baby

  • How to extract the audio of a zip file? if it helps I'm trying to add this album zip to my library

    how to extract the audio of a zip file? if it helps I'm trying to add this album zip to my library

    Let's say you have a zipped audio collection (audio.zip) containing mp3 files. And you are at a Terminal prompt.
    List the files in the zip archive
    unzip -l audio.zip (that is ell)
    Extract all mp3 audio files into a new home directory folder called mymusic
    unzip -d ~/mymusic audio.zip \*.mp3
    Variations of the above will depend the zip contents, and internal structure. If the zipped audio collection was gzipped, or someone used rar on it, then the extraction process will be different.

  • How to upload the invocie verify from excel file?

    How to upload the invocie verify from excel file?
    there is more items requied to input.
    refer to MIR7
    thanks

    How to upload the invocie verify from excel file?
    there is more items requied to input.
    refer to MIR7
    thanks

  • How to clean the trash forever from locked files?

    How to clean the trash forever from locked files?

    Depends on what the problem is, but holding down the option key while emptying the trash will bypass the locked status and delete the files.
    If those files are still in use (or the Finder thinks so), they cannot be deleted in the normal way. If the option key trick doesn't work, we can use the terminal.

  • How to extract the historical data from R/3

    hi
    I am extracting data from R/3 through LO Extraction. client asked me to enhance the data source by adding field. i have enhanced the field and wrote exit to populate the data for that field.
    how to extract the historical data into BI for the enhanced field. already delta load is running in BI.
    regards

    Hi Satish,
    As per SAP Standard also the best way is to delete whole data from the cube and then load the data from set up tables as you have enhanced the data source.
    After data source enhancement it is supported to load normally because you don't get any historical data for that field.
    Best way is to take down time from the users, normally we do in weekends/non-business hours.
    Then fill the set-up tables; if the data is of huge volume you can adopt parallel mechanism like:
    1. Load set-up tables by yearly basis as a background job.
    2. Load set-up tables by yearly basis with posting periods from jan 1st to 31st dec of any year basis as a background job.
    This can make your self easier and faster for load of set-up tables. After filling up set-up tables. You can unlock all users as there is no worries of postings.
    Then after you can load all the data into BI first into PSA and then into Cube.
    Regards,
    Ravi Kanth.

  • How to extract the signal out from the waveform by my designated power level?

    Dear all,
         How can  I extract the signal from the waveform accroding to the power level? I read the Trigger&Gate.vi, but this vi extract signal according to the duration time. I want to extract signal according to power level.
         As shown in the following figures, the signal I want to process is between 130000 to 140000, if I zoom in, I can see the the useful signal is between 135400 to 138200. The question is how to extract the signal in the zone?  
        I tried the sub_NoiseEst_And_Chop_Shell.vi in the Packet_based_link example too, but this subvi seemed to be a little slow. Can anybody give me better advice? Thanks in advance!
    Solved!
    Go to Solution.

    I was working on something similar but haven't had time to fully develop it.
    My idea was to use an envelope detector (low pass filter) and then use an energy detection VI on the envelope.
    Here's where I left off
    Anthony F.
    Product Marketing Engineer
    National Instruments
    Attachments:
    test.vi ‏331 KB

  • How to display the PPT, PDF, XL, DOC files with in the Windows store app?

    Hi,
    I would like to display the PPT, PDF, XL, DOC files with in the Windows store app? is there any controls provided by Microsoft to view these files with in the app?
    Or
    Any workaround to achieve the desired functionality?
    Kindly provide your inputs if any one has.
    Regards
    Prasad

    Hi Prasad,
    As I know currently there is no in-build functionality to display the PPT, XLS or DOC file directly on the Windows Store App, but you can always open these files by
    Launcher class
    However a good news is we can display PDF on Windows Store App by
    Windows.Data.Pdf class, see this for more information:
    https://code.msdn.microsoft.com/windowsapps/PDF-viewer-showcase-sample-39ced1e8/
    --James
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • How to extract the budget data from essbase to Ms access database

    Hi,
    i want to know how to extract budget dat fro hyperion to Ms access database
    please help me in this regard how to proceed, and what are the process i need to follow
    Regards
    Hypuser

    You can write a Calc script to export only the 'Budget' data and loaded back the exported file into MS Database via Loader or import.
    Cheers
    Cnee:)

  • How to extract the Title info from multiple PDFs

    Is there a utility or some program that will extract the Title info (located in the Title field under the Description tab from Document Properties)? I have hundreds of PDFs that I would like to be able to have extracted into some txt file or excel file. Any ideas? Thanks!

    I was working on something similar but haven't had time to fully develop it.
    My idea was to use an envelope detector (low pass filter) and then use an energy detection VI on the envelope.
    Here's where I left off
    Anthony F.
    Product Marketing Engineer
    National Instruments
    Attachments:
    test.vi ‏331 KB

  • How to select the max rowid from a subquery with group by

    Hi Gurus,
    Kindly help how to fix the following query because I'm getting Oracle error:ORA-01446.
    select * from edy_raw_data a
    where rowid in ( select max(rowid) from(
    select email,max(date_updated) from edy_raw_data b
    where b.email=a.email
    group by email ))
    The query select the max rowid from a sub query with group by.
    Thanks in Advance.
    Benjie

    Why do you need to compare with rowid?
    Wouldn't this suffice?
    select * from edy_raw_data a
    where (email,date_updated) = (select email, max(date_updated) from edy_raw_data b
                        where b.email=a.email
                        group by b.email ))* Note: untested

  • [solved]how to extract recent log entries from a file (based on time)?

    I have a daily log file with hundreds of thousands of entries in the following format. 
    field1,field2,field3,field4,field5,field6,field7,field8,field9,20110516192001.100
    field1,field2,field3,field4,field5,field6,field7,field8,field9,20110516192002.200
    field1,field2,field3,field4,field5,field6,field7,field8,field9,20110516192003.300
    field1,field2,field3,field4,field5,field6,field7,field8,field9,20110516192004.400
    field1,field2,field3,field4,field5,field6,field7,field8,field9,20110516192005.500
    It's always in the same format and the 10th field is always the timestamp (YYYYMMDDHHMMSS.MS)
    Since the file rotates daily, the 10th field will always be 20110516xxxxxx.xxx for today and will be 20110517xxxxxx.xxx tomorrow
    What I want to do is only look at entries that have been written in the last 30 minutes.
    At a high level, here's my plan
    1) Get the date/time from 30 minutes ago... write it to a variable
    2) Iterate through the file line by line comparing the 10th field to the variable, if it's larger write the line to a tmp file
    3) Use tmp file for my analysis
    This seems incredibly inefficient to me...  what would be a more graceful way to do it?  I have regular solaris tools at my disposal (plus python)
    Thanks
    Last edited by oliver (2011-05-17 12:41:43)

    The algorith you describe really is a viable approach.  Since this is a log file, each line should have a time stamp later than all lines that preceed it in the file. A more efficient algoithm could do a binary search through the file for the time stamp you are interested in.  This would be easy enough in to do in C or python, but your algoithm could be fast enough. If this is the case, you could try the following quick & dirty bash script.
    #!/bin/bash
    seconds() {
    secs=$(($1 % 100))
    mins=$(($1 / 100 % 100))
    hrs=$(($1 / 10000 % 100))
    days=$(($1 / 1000000 % 100))
    month=$(($1 / 100000000 % 100))
    year=$(($1 / 10000000000))
    (LC_TIME=C date +%s -d $(printf "%d-%02d-%02d %2d:%02d:%02d" $year $month $days $hrs $mins $secs))
    found=0
    now=$(date +%s)
    while read line
    do
    if [ "$found" -eq "0" ]
    then
    ts=${line##*,}
    ts=$(seconds ${ts%.*})
    diff=$(( ($now - $ts)/60 ))
    [[ $diff -lt "30" ]] && found=1
    fi
    [[ $found -ne 0 ]] && echo "$line"
    done < $1
    It will write (to stdout) all lines following the first line that has been time stamped within the last 30 minutes (ignoring milliseconds). You could redirect the output of this script to a file of your choice for analysis as follows:
    $ ./script logfile > tmp
    Last edited by rockin turtle (2011-05-17 06:58:41)

  • How to get the SSO user from PL/SQL with Windows native authen

    I connect to a 10g daabase using SSO through Windows Native Authentication wher the OID user mapps to a single Database user.
    I need to get the SSO user from pl/sql
    My fornt end is Portal & Forms

    Hmm, I see.
    Well your problem boils down to being in the database and needing to have access to web environment variables. The SSO sets specific variables in the environment but your stored procedure is not privy to them.
    Now having said that, note that the mod_plsql Web Toolkit has a utility for accessing cgi variables. For instance,
    owa_util.get_cgi_env('Osso-User-Dn')
    If your web application cannot capture the SSO info and pass it to the stored proc in a parameter, OWA may be the only way.
    Check out the Single Sign-On Developers Guide, specifically the part about developing statically protected PLSQL applications.
    Hope this helps.
    regards,
    tt

  • How to Extract the Hierarchy Set from R/3 into BW

    Hi all,
         A Hierarchy Set Z_XX has been created for 0STKEYFIG InfoObject with the  
    following details in R/3 for :
         Table: CCSS
         Field:  STAGR (Statistical Key Figure).
      I have tried to Refresh the Hierarchies with ' Available Hierarchies from OLTP'   button on 'Hierarchy Selection' tab from Hierarchy InfoPackage, but I didn't find this new Hierarchy set.
    How to bring this Set in to BW? Does it require any other process in R/3 side, PLEASE ?
    Thanks.

    Hi Voodi,
       When I clicked 'Where Used' button then 'Display Set : Subordinate Sets' displayed with the following info.
    No.           Set Id
    001     Z_36_STAT_CDVHSMSOLD     TOTAL HSM SOLD-COMBINED
    002     Z_36_STAT_CDVKGSCONS     Kilograms of Rollstock Consumed
    003     Z_36_STAT_CDVLBSCONS     Pounds of Rollstock Consumed
    004     Z_36_STAT_CDVMSFSOLD     MSF SOLD - Combined
    Thanks.

  • How to Update the DataSet populating from Stored Procedure with SYS_REFCURS

    I created a dataset with the wizard of VS2010 and link each DataTableAdapter stored procedures to insert, update, delete and select (which returns a SYS_REFCURSOR). When you run the program recovery and visualize data in a form, but if I want to update data, there is no change. Use the following code to update, insert and delete:
    BindinSourceEmployee.EndEdit ()
    EmployeeTableAdapter.Update (DataSetHR.Employees)
    Roberto

    What is the problem you are trying to solve?
    Presumably, when you're creating a stored procedure, you know what schema owns it. So it's pretty trivial to simply create a local variable L_OWNER in your procedure, assign it the value of the schema owner, and then use that owner. Most people don't really need to figure out at runtime what they already knew at compile time.
    Barring that, you could inspect the data dictionary as user130038 suggested. That requires that you know the name of the procedure (which would likely also have to be a local variable that is initialized to a hard-coded value. And if there are multiple users that own procedures with the same name, it may not be reliable.
    Inspecting the call stack is the most reliable and dynamic approach. But it is also the most costly in terms or runtime performance and in terms of code complexity.
    Justin

Maybe you are looking for

  • Sharing More than One Movie with iDVD????

    Okay.. I would like to know if there is another way to burn MORE than one movie an iDVD project. It seems that sending the movie straight to iDVD creates it's own project, and when you try to send another movie, it creates a completely different proj

  • Be aware when using a custom domain name

    Accessing your site on the iPhone by going to http://gallery.me.com/yourname here works fine. If you have a personal domain pointing to http://gallery.me.com/yournamehere - the site doesn't render on the iPhone correctly. I called tech support, Apple

  • Java 6 updates 22 thru 24 does not allow ASP Remote Scripting calls

    The Java 6 update 22 thru 24 all prevent ASP Remote Scripting from working correctly, causing applications using Remote Scripting via the standardized rs.htm code to fail. This is well documented with examples at the Java Forums page http://www.java-

  • Flash 8.5 Beta fixed my problems

    I'm running 10.4.6 on G4 Powerbook 1.25 and Safari started randomly not playing any flash movies version 7 or 8. I uninstalled the plugin using the unistaller from Macromedia then installed Flash plugin 8.5 (beta) and no problems here. It fixed my fl

  • Number of a specific day within a specific period

    Hi all, I want to form a query something like - "select count(saturdays) between '01/01/2007' and '31/12/2007' " And the output should be like this - Count 53 not sure, if 53 is correct or not. And one more query which returns like this - Saturday fa