Thread: Iris Recognition Program

  1. #1
    Registered User
    Join Date
    Jul 2018
    Posts
    3

    Iris Recognition Program

    hello everyone,
    i found an interesting iris scanning project on github,(GitHub - e-radu/irisRec: iris recognition for zybo). However i cant get it running.
    i have cracked my head around this program for a month but i cannot see it working. Please help me make this project run on Linux machine

  2. #2
    C++ Witch laserlight's Avatar
    Join Date
    Oct 2003
    Location
    Singapore
    Posts
    27,244
    What exactly are the difficulties that you faced when attempting to get it running?
    Quote Originally Posted by Bjarne Stroustrup (2000-10-14)
    I get maybe two dozen requests for help with some sort of programming or design problem every day. Most have more sense than to send me hundreds of lines of code. If they do, I ask them to find the smallest example that exhibits the problem and send me that. Mostly, they then find the error themselves. "Finding the smallest program that demonstrates the error" is a powerful debugging tool.
    Look up a C++ Reference and learn How To Ask Questions The Smart Way

  3. #3
    Registered User
    Join Date
    Jul 2018
    Posts
    3
    Quote Originally Posted by laserlight View Post
    What exactly are the difficulties that you faced when attempting to get it running?
    first, when adding a user to the database. it will print segmentation done...encoding done but it will not add the image to the database. i.e it will not print "4 images added to the database.

    second,when comparing a user to the database,it will print segmentation done...matching done. but it will not print that the user is in database or user is not in database which is its main use.

    lastly, i found that int support_grbg = 0 has been initialized to 0 but later has been assigned value of 1.

    Code:
    int support_grbg10 = 0;
    
            struct v4l2_fmtdesc fmtdesc = {0};
            memset(&fmtdesc, 0, sizeof(fmtdesc));
            fmtdesc.index = 0;
            fmtdesc.type = V4L2_BUF_TYPE_VIDEO_CAPTURE;
            char fourcc[5] = {0};
            char c, e;
            printf("  FMT : CE Desc\n--------------------\n");
            while (0 == xioctl(fd, VIDIOC_ENUM_FMT, &fmtdesc))
            {
                    strncpy(fourcc, (char *)&fmtdesc.pixelformat, 4);
                    if (fmtdesc.pixelformat == V4L2_PIX_FMT_SGRBG10)
                        support_grbg10 = 1;
                    c = fmtdesc.flags & 1? 'C' : ' ';
                    e = fmtdesc.flags & 2? 'E' : ' ';
                    printf("  %s: %c%c %s\n", fourcc, c, e, fmtdesc.description);
                    fmtdesc.index++;
            }

  4. #4
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    37,532
    So it's a project over 3 years old with a single commit.

    Most likely, the author just dumped it on GitHub for safe keeping, then either forgot about it, or found something else to do.

    I guess everything that it doesn't do means code hasn't been implemented yet.

    If you're looking to get up and running quicker than doing everything yourself, I would suggest finding a more mature project.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

  5. #5
    Registered User
    Join Date
    Jul 2018
    Posts
    3
    Quote Originally Posted by Salem View Post
    So it's a project over 3 years old with a single commit.

    Most likely, the author just dumped it on GitHub for safe keeping, then either forgot about it, or found something else to do.

    I guess everything that it doesn't do means code hasn't been implemented yet.

    If you're looking to get up and running quicker than doing everything yourself, I would suggest finding a more mature project.
    Actually,he implemented it on Iris Recognition on Zybo: 12 Steps . But i cant make it work on my side

  6. #6
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    Location
    The edge of the known universe
    Posts
    37,532
    What arguments do you pass to the program when you run it?

    > while((opt = getopt(argc, argv, "d:a:")) != -1)
    It appears to accept a couple of parameters.

    By default, it reads "/dev/video0"
    - Does this device exist on your system?
    - Are you able to access it as a 'normal' user, or do you have to be a 'root' user?

    Try to be more informative than "it doesn't work".

    Eg.
    Code:
    $ gdb -q ./irisRec_v1
    Reading symbols from ./irisRec_v1...done.
    (gdb) run
    Starting program: ./irisRec_v1 
    [Thread debugging using libthread_db enabled]
    Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
    Opening device /dev/video0
    Users in database: 1
    Opening video device: No such file or directory
    Video device: /dev/video0[Inferior 1 (process 10567) exited with code 0377]
    
    # running program with command line parameters
    (gdb) run -d /foo/bar
    Starting program: ./irisRec_v1 -d /foo/bar
    [Thread debugging using libthread_db enabled]
    Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
    Opening device /foo/bar
    Users in database: 1
    Opening video device: No such file or directory
    Video device: /foo/bar[Inferior 1 (process 10574) exited with code 0377]
    (gdb)
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Sound Recognition
    By Lesshardtofind in forum Game Programming
    Replies: 5
    Last Post: 07-25-2010, 05:36 AM
  2. Character recognition...
    By miltecnico in forum C Programming
    Replies: 19
    Last Post: 03-19-2004, 01:06 PM
  3. Face recognition...
    By rahaydenuk in forum A Brief History of Cprogramming.com
    Replies: 4
    Last Post: 07-06-2003, 03:11 PM
  4. Microphone recognition...
    By weraw in forum C Programming
    Replies: 2
    Last Post: 12-26-2001, 11:11 AM

Tags for this Thread