ARC Pro

Upgrade to ARC Pro

Harnessing the power of ARC Pro, your robot can be more than just a simple automated machine.

#2  

its not a very simple process. There are a lot of commands that have to be programmed to use this camera sensor. It is going to take some time to get an interface built to this camera sensor.

As far as hooking it up directly to the EZ-B, I am not sure that is the route you want to go, but it hasn't been tested.

I have tested the sensor with their application and it works as advertised. I am now in the process of using an arduino mini pro to interface between the EZ-B/Other devices and the HVC B5T. This allows for a layer of abstraction so that commands being sent to the camera are more user friendly. The arduino will handle the conversion of these commands to the commands needed for the HVC B5T to function. This also allows the camera sensor to be platform agnostic. I will let you know when I have made some progress on it. I am currently waiting on a cable end that will allow me to connect to the HVC B5T. Once I have that and I make a cable I will be able to really dig into it.

#3  

thanks guys for the replies. this sensor will be a game changer for robotics.

@d.cochran i look forwards to your progress on this.

#4  

Quick question. Looking at the board, the camera seems to plug into it. Is this the case?

If so, I would imagine a cam with an extender lead could be plugged in as well, allowing the cam to be located apart from the board. This would be helpful for mounting in small places (like JD's mohawk topped head).

#5  

There are two modules on the dev board. It has a communications module which plugs into the back of the sensor module. The production board doesnt do this. It has the single top board and is about 1/4 the cost.

The sensor is on the piece with the camera, all one board. The pins on the back of the production module are dead. You have to use the pins on the side of the module to connect to it.

#6  

@d.cochran Thanks for the response. Assuming your last post was in answer to my question, I don't think I was quite clear enough, sorry. So I've included a picture.

User-inserted image

The connector to which I was referring is pointed to by the arrow. It appears the camera module simply plugs into that little white connector. Is that true, and is it that way on the upcoming production offering?

#7  

ah, yes, that is the connection to the camera but the camera is mounted on the board. I assume it could be removed but I am not going to try it:)

#8  

Omron sells a lot of various sensors. I dont know if they are looking at putting a higher rec camera on or not. Both the dev board and the prod board were setup like that. I saw it and though "Wonder why they did that" but that is about as far as I went on it.

#9  

@nanomole40, not for sure what your looking for or to do, but there is also the OpenMV Cam that will talk I2C or Serial.

OpenMV Cam

#10  

Hi David!

I see you are still @ work with the Omron Board!

Greetinxx

Boris

#11  

Yea, once the end for the cable I will need gets here I will start to dig into it. I have so much to work on and this is just one of about 50 things I have to get working. It does need to be done so I might as well do it sooner rather than later.

#12  

Cool David!

If you need help (like some chinese work) tell me, i will help!

Boris

PRO
USA
#13  

I'm hoping with DJs announcement with the support for developers and plugins, that lots of fold will start writing for lots of support for all kinds of Hardware like this sensor. And you can make money at it...

#14  

I should have a plugin for this sensor in about a week. I have c# getting almost all of the data from this sensor and returning it to a dictionary. Time permitting, I should have a plugin completed in about a week.

#15  

The plugin doesn't use an arduino for communication. it does use a usb/ttl device for communication. I will post information on the one i am using. It uses a baud rate of 921,600 bps. The plugin will require that you have an on board computer. The code will be open source as I am using some things from an open source project. This plugin uses a python app to communicate with the Omron, which then passes back json. The plugin processes the json and provides the variables to ARC. In order to keep the payload light, I won't be passing back the video or image.

This version doesn't do facial recognition. I will be adding those features later. I will post STL files for a case for the sensor, the python script for communicating with the Omron and the plugin for processing the JSON.

PRO
Synthiam
#16  

What's the advantage of using this? Specifically since the ARC mobile app has color, motion, face, multi color and glyph tracking built-in?

#17  

It is really good at facial recognition. It is better than what I have seen from OpenCV, Aforge, ARC or RoboRealm. I don't have this piece implemented yet but Toymaker does and the Example Project works wonderfully even in different lighting conditions (within reason). The sensor can store up to 500 faces for recognition.

In addition to this, it does human body detection - Number of human bodies within view of the camera Age estimation - Does a really good job of identifying the approximate age of the people in the view of the camera. Gender Estimation - Is the person male, female or unknown. Hand detection - can differentiate between how many fingers you are holding up Expression estimation - is the person happy, sad, upset, neutral or whatever eye estimation - location of the eyes and how open they are Gaze estimation- where is the person looking?

Any or all of these can be enabled or disabled. This helps to make the robot smarter. Tracking would be done by another camera while this one handles the person recognition. This reduces the load on the computer running ARC. Also, it allows ARC to still do color tracking and whatever through other cameras.

All of this is done on the sensor so very little processing load in handled by the light weight tablets that people put on their robots.

Here is a sample of the data returned.

Detection execution:

body: num_detections: 0

face: detect_size: 106 reliability: 632 num_detections: 1 coord_y: 379 coord_x: 245

gaze_estimation: left_and_right_angle: -2 up_and_down_angle: 0

gender_estimation: gender: man reliability: 1000

age_estimation: age: 51 reliability: 285

face_orientation: face_inclination_angle: -1 vertical_angle: 13 reliability: 43 left_and_right_direction: -6

facial_expression: neg_pos_degree: -57 top_score: 43 expression: expressionless

eyes_estimation: eyes_head_right: 337 eyes_head_left: 399

hand: num_detections: 0

PRO
USA
#18  

David really looking forward to the plug in.

#20  

Hello David!

it´s sounds good!

I am still have this omron board. But tell me, your plugin work only with your USB board (800 ,-) or also with my cheap Board without the USB connection?

Best Boris

#21  

the board I use is about $10 USD and is very common. I should have the first version of the plugin out in a day or so.

#22  

Hello David,

still it sound really good!

Slowly i must work again on my Inmoov after 4 Month break!

So some days waiting is no problem! ;-)

Boris

#23  

just posted it. The description has the information you need to use. I will update the description more in time.

#24  

@RentaPrinta, this will show you how to use the plugin when you are ready. Sorry it took so long to get to you. I have been really busy with other things and finally got back to this. I will work on adding Facial Recognition in the future, but you now have a control in ARC that allows you to use this sensor.

#25  

@david- thank you for all your hard work and looking into this I am going to try this out at the weekend.

will be well worth it !

#26  

Superawesome piece of tech....how could I miss out that @david is already working on it! I will get down to it asap! You are working out great stuff for all of us @CochranRobotics rules!:D

PRO
USA
#27  

Nice job. Looking forward to you adding facial recognition!

#28  

Thank you. I have the sensor returning the userid and score of the recognized users. The plugin will need to be expanded on in order to use this data.

To add users, I am currently using the demo app that is supplied with the sensor. I am working on what needs to happen within the plugin to get the recognized user name from the data file that is created by the demo app. Once done, I will then look at what is needed to setup the process for adding new users (to the local data file and to the sensor).

The good news is that I am able to get the information that is provided from the sensor for facial recognition. You could use an if statement to say something like


if($omron_recognized_user = 0)
  $username = "David"
end if
if($omron_recognized_user = 1)
 $username = "Nick"
end if

but, I am working on making this happen in the plugin instead.

#29  

Facial recognition is working inside of the plugin now. Adding faces isn't but the evaluation software has been included in the plugin to allow you to add faces to the Omron and local data files.

PRO
USA
#30  

Wow that was fast !

#31  

A full blown plugin with facial recognition - awesome David - thanks again !

#33  

I have looked at it. I would use it from my pods. I am big on multiple sensors validating information. Watson and Google also have services. I have more experience with Watson services.

I want as much processing to take place off of the tablet as possible. This sensor does this and does a great job of facial recognition, along with a few pieces of information that help the AI to make decisions.

#34  

Looks like Omron has the next hardware version P2.

PRO
United Kingdom
#35  

I am already using the P2 it is 4 times faster than the B5T with a separate camera (on ribbon cable) - the only other difference is that you can now only store 100 faces (on the base unit) whereas the original could store 500. Also there is 2 camera options 90 deg or 50 deg.

Tony

#36  

Yep, this is one I have been sitting and waiting for for a while now. Tony, do you know if there are any changes to the commands/received data from the HVC-P to the HVC-P2? I expect that they are the same but if you could verify, it would let me know if I need to update this plugin. Also, there appears to be a usb port on the HVC-P2. Is the comm chip now on the board eliminating the need for a separate board to handle the usb to serial conversion?

Thanks David

PRO
United Kingdom
#37  

I currently have a pre-production P2 and will be receiving two production units next week which have a different main PCB. Yes the P2 has UART 3v3 or USB CDC class ports.

The commands/received data are exactly the same for the HVC-P and HVC-P2 - I have found that you cannot use your existing HVC-P albums with the P2 so I produced new ones.

Tony

PRO
USA
#39  

Let me know how you get along. I'm very interested in its use in a toy line prototype. Is there a time line on the v2 's availability?

#40  

David, if interested, I may be able to send you one to test out.

#41  

I would love that. Im at a show this weekend but would love to test one out.

PRO
United Kingdom
#42  

@69developer, are you talking about the P2 here as they are not released yet? I have pre-production P2 units as I am dealing direct with Omron but as far as I am aware there are no production units out yet anywhere.

Tony

#43  

@Tony, yes the P2 and also have a pre-production of a Cognex camera that is very similar, but probably will be more expensive.

PRO
United Kingdom
#44  

Here is a first look at the new HVC-P2 sensors - they are still labelled samples as this is the first production run.

User-inserted image

Tony

#45  

I like that design much better than the original. It does cause me to redesign the top of the head of my Rafiki bot but it will be well worth it I believe.

#46  

Hi Toymaker,

they looks nice!

And how much are they?

Much more then the first version?

Best Boris

PRO
United Kingdom
#47  

These two units are for two further ALTAIR EZ:1 robot builds and they cost me £600 but this does include 20% VAT.

Tony

#48  

Uh, I just got me the old version of it...this one looks way better, the detached camera is so good to incorporate in any robot build, probably works better too!

Should I send it back and wait until the new version comes out? Man probably bad timing to buy one right? :/

PRO
United Kingdom
#49  

I think the P2 will be on general sale in October.

The differences to the P1 are

Detached camera Two camera types available Works around 4 times faster Can only store 100 faces/templates (P1 can do 500) Has on board USB interface

Tony

#50  

Hmmm, just got it today...maybe I should return it, if the new one is about to be released!

But it was 600 bucks for just one of them...or for the two? confused

#51  

If the cost of the board would be 600 each I would keep mine, if it is only 300 each I would return it and wait for the newer version...;)

PRO
United Kingdom
#52  

I paid £600 for the two P2 sensors.

#53  

Thanks @Toymaker thats a good deal for the detached camera...hope they will still change it!:)

#54  

you could also see if the Matrix/Rpi board will work for you?

#55  

Could you send me a link...is this also something that could be integrated to an EZ-Robot project? I never heard of it, I also only came across the Omron because I saw it over here and figured since there is a plugin for it I should give it a try!:)

#58  

Nice product...also the price tag is quiet reasonable! They might have tried to put a bit too much into the thing which makes it a kind of bulky and hard to fit into a custom build robot, but a really cool thing!

I also found something that might be worth checking out...right now you can only download a demo for Android and Windows, but lets see where they take us! Creepy how easy it gets to extract this kind of data!:D

http://www.humansensing.cs.cmu.edu/intraface/

#59  

I do believe the new P2 Omron sensors are out now.

#60  

Thanks for the Update...I could not ask if they would take mine and change it for the newer version until its been officially released!;)

Lets see...:)

#61  

btw, if they would change it...should I go for the standard or the wide angle version?:D

#62  

I personally went with the wide angle. Here are the differences:


Specifications 1600 x 1200 pixel detection resolution Horizontal detection range (angle of view) 54º (Long-distance type) 94º (Wide-angle type) Vertical detection range (angle of view) 41º (Long-distance type) 76º (Wide-angle type) Size 25 x 25mm camera board 45 x 45mm main board Body detection distance 17m (Long-distance type) 8m (Wide-angle type) Face detection distance 10m (Long-distance type) 5m (Wide-angle type) Hand detection 6m (Long-distance type) 3m (Wide-angle type) Distance for face direction, gaze, blink, age, gender and expression estimation, and face recognition 3m (Long-distance type) 1.5m (Wide-angle type)

PRO
USA
#63  

Will the current plugin David C created work with this version?

#64  

Per Tony, nothing has changed other than the recording and storing of the images some. It doesn't seem possible to move any existing images and id's to the new plugins structure. The plugin should work fine but you will need to record the faces and enter the ID's (possibly with software they provide?). I assume the old software they had would also work but would be for a smaller set of faces. I haven't had time to verify this or even order a new sensor though.

#66  

@CochranRobotics

Hi David, I have recorded and stored some faces using my new sensor/camera. I used a folder as requested by the HVCDemoE software that is supplied by Omron.

Have you found a way to use the facial recognition thru the plugin yet?

Thanks,

#67  

The plugin does facial recognition on the V1. What it doesnt do yet is record a face to the database from the plugin. Right now, you have to record the faces using the omron example app and then copy over the text file. The way the omron works is that it returns an ID of the face. The plugin looks for the name associated with that ID in the text file and returns that name. I havent had a chance yet to try out the V2 with their new software. I assume that they have made a change to the text file, but I havent had a chance yet to look into the new software.

#68  

The facial information (Album) is stored in a folder called " HVCAlbum.hac ". I currently have it located in my Document folder. Should I move it somewhere else or how do I point to it?

#69  

can you copy that and email it to me? i will see if the foemat changed with the new version.

#70  

I will first try a reload of the software. Maybe I corrupted it messing around with the album for the facial recognition. I will let you know how I make out. I wasn't sure you had gotten the recognition part working in the plugin. Now that I know it is okay, I will see what I may have messed up.

#71  

Hi David, Hi Andy,

With Version 2 David plugin also work!

Only the Names what i save with Version 2 are not shown in Davids Plugin!

You must use the old Software (But you can use the new Camera/Board) and all works.

Only if you use the new Software you will have Problems with the saved Names of the facial recognition.

But this i told David.

https://synthiam.com/Community/Questions/10350

Boris

#72  

The Omron seems to be hot gossip again... time to take mine off the shelf!:)

Its been sitting there since I realized it could not be returned and changed for the newer version! So I guess I should get started now...:D

#73  

Bois, Thanks for the info. This answers my concern.

@Mickey You really need to play with this sensor. I got my robot say Hello to me and my wife and when I get the software (maybe the old version) working, he will greet everyone he knows. I used the "man or woman" to determine my or my wife's name. Works great. At almost 1/3 more in cost, I don't see a big advantage other than the packaging.

#74  

I am not concerned with the number of faces stored. My need shouldn't exceed 100.

Where can I find the old software?

#75  

It is included with the plugin.

C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0

#76  

OOPS. I didn't look... Sorry

I will load it up and try it soon. Thanks.

#77  

No problem at all. It looks like the files used between V1 and V2 of the software for storing the face recognition information has changed. I will hopefully have time tomorrow to look at what it would take to make this change. I think that I will try to first look in one file and then the other in the plugin or I might give the user the ability to choose which version of the Omron software was used for saving faces. Today is pretty full but I hope to be able to have time to look into it tomorrow.

Thanks David

#78  

Hey Man, you need a break.... when ever you get a chance. I'm sure we all can wait. I have a mess now. I think I have both software versions in the same folder. Oh well I will blow it out and load the new one again, once you get stuff sorted out. It still works .

API is next !

Thanks,

#79  

I have to copy cat and be like David and Tony as I just ordered an HVC P1 and while I'm waiting for it to come in I was day dreaming about uses and a jerry rigged thought occurred to me, and I wonder if anyone tried this yet?

As the module requires a PC, my goal was to always run my robot from a base station without an onboard PC, so I'm planning to use the module on a tri pod near my desk and I thought, why not point the HVC camera at the monitor where the wireless camera feed from the EZB comes in anyway? I can't wait to try it to see the results.

#80  

It will be interesting to see how it works out. I think on a flat screen it wont be bad. It will be interesting to see if the refresh rate of the monitor and the camera have issues working together.

#81  

Update: The experiment I wanted to do: "...I'm planning to use the module on a tri pod near my desk and I thought, why not point the HVC-P1 camera at the monitor where the wireless camera feed from the EZB comes in anyway?"

I did this experiment with a WebCam that gives a live feed to a secondary monitor on my PC. I could then point my Omron HVC-P1 camera at the monitor and use the HVC-PDemoE.exe in the plug in folder for training and testing as well as with in the plugin in ARC. It does work.

It did not work for me for faces I trained which were not pointed at the monitor originally. The reverse was also true for me, I could not train a face on the monitor then turn the camera around to face me directly. I suspect this has a lot do with lighting conditions effecting the training.

It did seem to struggle more with my age and expression as well because, it judged me more often as "angry" and it usually put my age at about 20 years older than I really am.

#82  

A few of us have purchased this series of camera and have found it to be a great sensor. David Cochran had begun the delelopement of a plugin able to interface the data with the ARC. Has anyone been able to further develope additional features into this plug in? I have been able to get some data to transfer, but it is minimal. I know David is not able to work on this due to his work schedule. Can anyone help?

#83  

Hello Andy,

not that i know. I am still waiting for David that he updated the V2 Software. Still evrything works with David´s Plugin, only the Correct Names for the Person Recognition not work.

What you want to have else (feature) what David plugin not have?

Best Boris

#84  

Hi Boris. I just completely broke the plugin somehow. I was running it earlier today and now it won't communicate with the ARC. The Omron software runs fine. I checked the port and baud rate in my device manager which is ok (9600) and also in the plugin. But it comes up with a communication. I am considering deleting the Python folder and re-load. Any ideas?

David is really swamped at work so I don't think he will around for a while.

#85  

I re-loaded everything but same error shown on ARC.

#86  

Hi Andy,

give me 2- 3 hours i will check it.

Maybe something wrong with the EZB Software.

I will tell you if my works. I did´nt touch for 1 month.

I can also send you my folder from Omron / David Plugin.

Let´s see whats wrong.

Best Boris

#87  

Thanks Boris.. I know the camera is fine. I just seem to have lost the com. I reloaded the python and python serial software. I will check it out again later.

Ron

#88  

Boris, I reset my computer to an earlier date and all is running again. I must have had a conflict somewhere, or Antonn was mad at me.

I want to get the facial recognition working soon. Have you had any luck?

Thanks for the advice.

Ron

#89  

Hi Andy,

sorry my Saterday was to long yersterday.

I have a coffee and i will test.

But good for you - that it works again.

See u later.

Boris

#90  

Hi Andy,

So i am back @ my EZB Notebook. I did a EZB update and I also uninstall/delete and install new the Omron Plugin.

Still everything works except the Name Recognition. A question before:

You work with the new Omron Camera:

B5T-00701-020 with EvaluationSoftware_rev.2.4.1

And not:

B5T-001001 with EvaluationSoftware_v1.2.0 ?

What I did: After install the Plugin, I delete the whole files in the EvaluationSoftware_v1.2.0 folder from the plugin folder.

Then I start the Software from the new Version EvaluationSoftware_rev.2.4.1 make a Album with 8 Photos from me and save it to Flash and as a *.hac file into the root plugin folder. Then I copy all files from the EvaluationSoftware_rev.2.4.1 into the empty EvaluationSoftware_v1.2.0 from the plugin folder.

Then I start EZB and the Plugin. I write a script:


:loop

ControlCommand("Omron HVC-P", Omron_Detect_Options, "r,f,b")

goto(loop)

And let him run.

I see @ the variable watch that the camera recognize a face and a body and properly a user name, but he will not send to the EZB.

Back in the original Software The Camera will show my NAME!

So I checked in the plugin folder the files and I found the folder script with the Phyton file hvcp.py - I open the file and I checked a little bit what David has programmed. I think somewhere in this script must be an entry for the User-Names for the old Omron Software. This must be change and then the plugin will work to 100%.

#91  

UPDATE:

I copy from the original software folder "EvaluationSoftware_rev.2.4.1/B5T-007001/0/" all files

"RegistData" folder "Device" and "Settings" files

to:

C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\DB\

Then i go to :

C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\DB\RegistData\000

and open with a Editor "UserInfo.dat"

I see this:


0
Boris
0,1,2,3,4,5,6,7

i change to this:


0
Boris
Boris

And funny way it works now!

I am not shure if this is all, BUT now it works!

You can check yourself!

Boris

#92  

Other Question:

I got Values for $Omron_face_CoordY for Example "704"

BUT for $Omron_face_CoordX everytime "0"

This is also an error.

Boris

#93  

Next week I will try your changes. Thank you for sharing them. Ron

#94  

Hi Andy,

no prob!

Tell me if it works.

I am also interested to do something with the Omron Face Reco with sense.

Only say: Hello Boris! If the Camera recognize me, is a little bit boring.

Ok - it give the possiblitie that the Omron can ask me why i am Happy or Angry...

( After the Camera maybe check 10 times the SAME emotionally state from me)

Or the Omron ask - why you look up - look down

Closing Eyes - Is more for not sleeping when you are driving! ;-)

And the age and gender? I know how old iam what i am ;-)

So maybe someone has another ideas what the Omron Camera can do.

Best Boris

#95  

Hello again Boris,

Some of the things I plan on doing is open text files which will allow discussions for the person the camera sees.

@JustinRatliff has been working with the use of text files which should allow the camera to do a lot more. This way if the camera sees a different person, it will speak about the things set up for that person.

An example is I like Football. My wife likes Basketball. When one of us sits with the robot and we discuss sports, the robot will speak to us about the sport we like.

Gender and age could be used with facial recognition to help confirm the person it is speaking to. Age is good if a child is seen., maybe for games to play.

Emotion ? I don't know. Blink, gaze, etc. ? I think these are more for the commercial use of the camera.

#96  

Boris and other Omron Camera users,

I have no knowledge of Python and am not a programmer in any way. Is it possible to build a plugin which will allow the loading of facial recognition information, files, pictures and name into the Omron software?

A separate "Data Load" script would be used to copy in say, 8 pictures with a statement "smile" prior to each picture load. A name would have to be typed in later or maybe "text to speech" to load the name?

Just a question from a non-programmer, Omron camera user.

#97  

The "Data Load" has always been one of the hottest questions of any vision recognition because once you have something that works like ARC with it's object recognition or back in the day with my old EZ-Face or RoboRealm or with the Omron camera now, it sounds so handy to load a data set instead of the manual training interface.

While things like ARC, EZ-Face, RoboRealm are all examples of software the Omron camera is really a hardware solution, so that plays a part in if it would be doable or not.

When you run the demo program for the Omron the software is communicating with the Camera and the Camera is doing all the work, not the software, so when it recognizes a face it is actually the hardware of the camera doing the work and answering back telling the software on the computer what it saw.

So when you train a face with the Omron the hardware of the Omron has to be able to say "I understood what I saw and I accept what I saw" otherwise the Omron would report something like "Ptt, error, try again" (obviously that is not verbatim).

And it's the Omron camera hardware that does the math to make the picture that gets stored in the software database that is also synced with the Omron camera hardware.

I think it would technology possible to create a new software or plugin that could control the Omron Camera to do that tasks. I think it would be a complex project to undertake as well.

#98  

Hi Justin,

Thanks for the explanation. For now I will plan on loading faces manually using the Omron software. Hopefully with Boris' suggestions, I will be able to use scripting in the ARC. I will then use separate scripting to work with unknown faces based on gender and age. This way I will still get the interaction I want.

Ron

#99  

Hi Andy,

with this stranges "folder-copy" is funny way working.

So it´s also for me really interessting if it works also for you.

Boris

#100  

Hi Boris,

I will be trying your "folder-copy" soon. Work has me busy again.

I will definitely get back to you with the results. I will at least try the changing to the new version as soon as I can.

Thanks, Ron

#101  

Hi Andy,

no Problem!

Meanwhile i will play also a little bit the camera.

Boris

#102  

EDIT AGAIN! Boris, what you did in post #92 is correct but I think you listed the steps incorrectly. Because it makes it sounds like you are directing people to edit the file in the primary folder of: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\HVC-P\0\RegistData\000

And the data in the "UserInfo.dat" file is the stored results of your captured faces.


0
Boris
0,1,2,3,4,5,6,7

The information contained in the file as as follows: User ID: = 0 User Name you provided: = Boris The stored reference pictures you took: = 0,1,2,3,4,5,6,7

EDIT There is a new UserInfo.dat file created for each user trained. The first is in folder 000, the next is 001, the next would be 002 and each user get their own folder and their own UserInfo.dat file in each folder.

If you edit the last line to reflect "Boris" you will create an error and force the first picture stored and only that one to be used. This will lower your recognition rate.

#103  

So, what Boris said to do in post #91 and then in #92 is correct, but I think in post #92 Boris did not list the steps clearly. I'm going to re-write his directions here to update the plugin so that it works with the EvaluationSoftware_rev.2.4.1 version of the Omron software.

I have the older HVC-P1 and these steps works for me and my HVC-P1 as well. In fact it provides me with greatly improved results over the older EvaluationSoftware in the plugin because I was encountering a lot of recognition failures with the older software.

**HVC-P1 Owners - if you are not encountering issues, I would not bother with upgrading if you are happy with the results you have. These steps are for those that want to upgrade and or want the variable in ARC $Omron_Recognized_Name to display correctly for their HVC-P2 camera.

Step 1. Download the updated EvaluationSoftware_rev.2.4.1 software if you do not have it. You can get it from the Omron site here under Product Information tab and Evaluation Software: https://www.components.omron.com/mobile/hvc_p2?nodeId=40701010

Step 2. Extract the .zip file and try out the new HVCDemoE.exe program. You will also find an application called HVCDemo.exe which you can delete if you want because it is an Asian language version.

Step 3. Install the PlugIn for the Omron if you have not already done so. Make sure you install are required drivers for the Plugin. If you have already completed this, move to step 4.

Step 4. Locate the plugin folder, which should be located here under your Users\Public\Documents folder, depending on your version of Windows the location path might be a little different, under Windows 10 is should be: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb

Step 5. In the plugin folder, locate the folder named "EvaluationSoftware_v1.2.0", open this folder and delete all of the contents of it.

Step 6. Locate your folder named EvaluationSoftware_rev.2.4.1, open it and COPY all of the contents of this folder and then PASTE the contents in the now empty EvaluationSoftware_v1.2.0 folder which is in your plugin folder.

Step 7. Open the HVCDemoE.exe application which should now be in your plugin folder under the EvaluationSoftware_v1.2.0 folder.

Step 8. Set your options and do a test camera click to make sure you get good results. You may need to select the Transfer Image Size in the drop down if nothing is select. If your picture is sideways, the default camera view was set to 0 instead of 270, you will need to click on Setting in the application to adjust that.

Step 9. Under Settings in the application, click on the Maintenance tab click "Delete All Data" if you previously trained any face, this will clear out any data between the application and camera so all fresh data can be used.

Step 10. Under the Album tab of the application, go through the steps to train user faces. You can train up to 10 pictures per user stored. When you are finished click Save, when you are prompted for a location, save the .hac file as "EvaluationSoftware_v1.2.0.hac" in the root path of the plugin folder: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb You will also be asked to sync the data with the camera and you should do that as well.

Step 11. Click on the Main tab in the application and click on the camera to test recognition to see if it now displays names correctly for trained faces.

Step 12. Close the application.

Steps 13 and 14 will make a copy of the trained faces data and put them in a location so the plugin can make use of the name value, while step 15 through 17 edits the file(s) so the name will display in ARC.

Step 13. Locate the folder RegistData in the plugin folder and COPY the entire folder. The path is here: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\HVC-P\0\RegistData

Step 14: Paste the "RegistData" folder into the DB folder which is located here: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\DB

This makes a copy of the trained faced. **If you ever update any of the trained faces you will need to duplicate Steps 13 and 14 so the contents of the RegistData folder can be recopied.

Step 15: Locate the file named "UserInfo.dat" inside of your newly copied .EvaluationSoftware_v1.2.0\DB\RegistData\000 folder. The full path is C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\DB\RegistData\000 Open this copy of UserInfo.dat by right clicking on it, select Open With then select Notepad as the application. If you are asked if you "ALWAYS" want to use this application for this file type do NOT check that option!

Step 16. You will see in the file the user ID, the name you gave the user and the number of picture you saved for the user. My file listed:


0
Justin
0,1,2,3,4,5,6,7,8,9

If you do nothing else, in ARC the values of last line are what would be read for the variable in ARC $Omron_Recognized_Name, in this case the variable would = 0,1,2,3,4,5,6,7,8,9

But it is important to note the variable $Omron_User_ID would still show the value of 0 because for me I was the first person or user I train so I get the ID of 0 so even without going further it would be possible to use the $Omron_User_ID value to recognize someone with IF THEN logic, which I believe David C. had previously stated would be possible (I'm just restating this for clarity).

So to correct the value for the variable $Omron_Recognized_Name, we need to edit the last lime of the file so that is reads:


0
Justin
Justin

After you edit the file, in Notepad, save it and close Notepad.

Step 17. Repeat steps 15 through 16 if you have additional trained users. Instead of folder 000, in .\EvaluationSoftware_v1.2.0\DB\RegistData\000 you would have folders named DB\RegistData\001, DB\RegistData\002, etc. And in each older would be a file named UserInfo.dat which would need to be edited.

Step 18. Open the HVCDemoE.exe program from your plugin folder to test the recognition again, it should work just the same because we did not alter the primary RegistData folder or UserInfo.dat file(s), we altered copied of them which the HVCDemoE.exe program should not be using directly.

Step 19. Open ARC, create a new project and add the Omron camera Control. Click on Configure button of the Omron Camera control in ARC to insure it is set correctly.

Step 20. Create a script to test the camera in ARC. You should add a Variable Watcher to your project as well, so you can see all the variables returned from the camera. You can refer to the test example from the plugin page or you can use mine which will continue to poll the camera for data until you end the script.

If you run my script below, the camera will be polled every 10 seconds to get a picture. It will keep a counter of how many time it has been polled as well as return a simple print statement for who is saw and their emotional state. If the camera saw no one it recognized by name, the print statement will say it saw no one.


$sCounter = 0

:loop

ControlCommand("Omron HVC-P", Omron_Detect_All)
 $sCounter = $sCounter + 1
 Print("Omron Camera Polled " + $sCounter + " Times.")

  If($Omron_Recognized_Name > "")
    Print("I saw " + $Omron_Recognized_Name + ". They were " + $Omron_expression + ".") 
  Else 
    Print("I saw no one.")
  EndIf 

 sleep(10000)
goto(loop)

Step 21. Special Optional Step If you ADD new users after the fact, you can either COPY the either start at Step 13 and copy the ENTIRE contents of the RegistData folder and follows the steps all the way through Step 17 to update the names

  • OR - you can locate the ./EvaluationSoftware_v1.2.0\HVC-P\0\RegistData folder and then locate the "User.dat" file and COPY it and PASTE a copy of it in the ./EvaluationSoftware_v1.2.0\DB\RegistData folder (this file holds a master copy of all the user IDs stored, if there is only one the file would include a single line of 000, if there was a second user the next number would be 001, etc).

Then go back to the ./EvaluationSoftware_v1.2.0\HVC-P\0\RegistData folder and COPY only the new users you have added such as folders 004, 005, 006, etc. (what every the folder names may be for you) and then PASTE a copy of only those missing folders in ./EvaluationSoftware_v1.2.0\DB\RegistData folder.

Then in each of those newly copied folders follow Steps 15 and 16 to update the names. That way you don't have to edit files you previously edited.

#104  

Boris and Justin thank you both for the procedure to get the face recognition info into ARC. This will now allow me to proceed with my Antonn projects. I appreciate your help.

#105  

Hi Justin,

Respect for this Doctor work!

I need a coffee and 30 min to read your Text.

But it sounds cool! I will check it out now!

Boris

#106  

Hi Justin!

You write it much better then me!

But I am not a natural writer more speaker ;-)

Everything is right but is not Point 13 diffrent?

Step 13. Locate the folder RegistData in the plugin folder and COPY the entire folder. The path is here: C:\Users\Public\Documents\EZ-Builder\Plugins\a9bdf8cb-7beb-4dc6-96cf-2fadfaaba8eb\EvaluationSoftware_v1.2.0\HVC-P\0\RegistData

I think @ this point i must copy the files from the 2.4.1 Folder to (Point 14) the 1.2.0 folder?

Or i am wrong?

Boris

#107  

Hi Justin,

other question:

With your script / or generaly a unknow user will get a random User-ID?

Like "23289" and score -23434

Your Script is working - I saw Boris - They were anger ;-) (Not true)

Boris

#108  

Hi Justin,

Ehmmmm....

Do you know why i get no value for "Omron_face_CoordX"?

For "Omron_face_CoordY" it will refresh the value

For "Omron_hand_CoordX" i get a value (but no hand in the picture)

So could a be possible that the values are change form FaceX and HandX?

Boris

#109  

Hi Boris,

Those are all good questions. For your questions in post #107 if you followed ALL of my steps my way is correct. But I would agree, you did a few things differently as far as the steps and the order than I did them, for example I think you directed training faces and saving your .hac file before coping the data over to the PlugIn. I think doing it that way risks introducing errors.

So we both did the same thing, I just tried to re-order the steps to minimize errors and break them down so hopeful more people can follow them. Because everything you originally discovered was correct. You deserve the credit!

For your questions in post #108, I think that is correct. I don't fully understand how the Omron assigns user IDs for unknown people but I am seeing that result like you. I am also seeing interesting numbers if more than one trained face is recognized.

For your questions in #109, I don't know either. I'm thinking we might need to dig into the source code of the plugin David C. created to see if we can gain some insight.

#110  

HI Justin!

No with your cool description is everything right! Ok if you record diffrently you may copy from this folder.

I record my Album in the 2.4.1 folder and then i copy all the Album files to the Omron Software folder from Davids plugin.

Nevermind - we got a solution for correct Name Recognition - This is what is important!

We will share the credits - I checkt out and find the right way with big luck and you write nice text for the community!

post#108 Yes it´s funny - but in the moment not so necessary.

post#109 This could more interesting for control a servo - Is the Face in X Postition - move servo - In Y Position move sero

Justin...... Interessting Question: I spoke last weeks with the Developer of the Pepper Robots and they not really costumer friendly (to say it nice ;-)) they only want to sell the Pepper for Supermarket Promotion but not for Events and Partys! So i checked out what the Pepper makes to Pepper:

Funny the biggest thing is a Emmotion Camera what recognize People and Emmotions.

So the Omron Camera!

My question is:

Do you have some cool ideas of programming in EZB the Omron Camera?

For Example - Emmotions: The Camera sees me and find out i am anger - now a script must save in a excel list that i was detected with anger emmotion @ date @ time. So now we can say if the Camera detect me in 1 hour 10 times with anger emmotion - EZB will ask me "Boris feel your right - you looking anger?"

So i mean - like normal humans - Nobody will tell me in the first second of minute of a meeting that i am looking suprise or anger.

Normaly you will ask or tell this after a while.

So and we know the Dectection of Emmotion is complicated ;-)

It would be better to check a number of values from a period of time and then calculated (ok the value with the highest count) the best emmotion.

But for this we need a Excel / Access Databes files where the script can save values!

Some ideas? .....

I build up the Inmoov and now i am redesign the Moveo Robot Arm - so i like robots and i feel a little bit p...ed off about this Pepper Product - Paying 25.000 and you can´t do with my payed product what i want to do.

OK is there Product and Bussiness.

So what is my Solution - I will show the world i am building a better ROBOT then they!

That´s why i am really interessted in the Omron Cam. What the Pepper can do - WE CAN DO BETTER

Boris

#111  

Hi Andy,

sound´s that it will work for you!

Cool!

the more people working with the Omron Camera, the better for us all!

Boris

PRO
USA
#112  

Agreed Boris, I have one but have yet to take outta the box. But this thread has me interested again.

#113  

HI fxrtst!

You have a Pepper?

I really want to have one - But not for 25.000 and not can earn money as a Event-Eyecatcher! For a toy it´s to much! I am not poor but i got a small car for this money.

So that´s why my power to do something against that. ;-)

It´s still a toy - not like the facbook chatbot who invent there own language what the developer not understand and then to be save it´s better to shut the power off.

;-)

The "Electronic being" begins to exist? !

But this is a diffrent story.

So a toy what check out a little bit emmotion - can tell me the weather and save some informationen about me ( Maybe my stand up time in the morning - with a "Good Morning Robot" Command - So in my Brain it´s easy but in software language it´s a more complicate site.

But nice to hear from you fxrtst.

PS:

My Familie had long long time (more then 100 years) a props rental for film and theater. If feel like in a museum of all centuries and the last decades.

But now in Germany is not much earning money with props in film business so thats why the closed and i was many years a House DJ and now i am working with printers. So how the life is funny.

Boris

#114  

Hello Boris and others,

I decided to look on the Omron site to see if they had more information and if they had a FAQ section. I went to https://plus-sensing.omron.com/ and found some information. I haven't really look around, but maybe if the users here ask questions on, for example the Emotion tab, and others, we can get answers about how it may be used and could return more accurate information for a more European looking face. (The device may be designed originally for different facial features.)

I will continue to look at the information and report back. It may take a while due to my work load and current Halloween project.

Ron

#115  

Hi Andy,

this sounds interesting! I did´nt know that they are some hints / cheats ;-)

I also will read!

Boris

#116  

I am still 20 seconds on the site and i rode:

Pet dectetion

Sence decetion

What da f***

The Rest i know but this.....

My heart is pumping!

i will read more

Boris

#117  

Happy I found it.... I am not able to read all yet, but I did find a tab where you can ask questions.

Hi Will, Which one do you have, P1 or P2?

Ron

#119  

HI,

idea:

It´s possible to connect two Omron Camera - or get the value from two Cameras - to get more relaible results for recongnition.

Take a wide and a long distance camera and get the result of the values of this two.

It can be really nice.

Someone an idea how manage the values from two cameras?

Boris

#120  

Boris, How about using the EZ robot camera (maybe with tracking or face recognition) and the Omron. Big cost savings and you get the best of both.

Use variables in a script to compare results.

I will have a computer in my robot so I can do both easily. I plan on the EZB camera to track to face or object then use the Omron for the rest.

Ron

#121  

Hi Andy,

yes i was thinking the same, but i must say the Omron is tausend times better for face recognition then the EZB Camera or a Logitech HD Webcam with EZB.

Propertly i want to use 2 Omrons wide and distance

A Webcam for Glymph, QR Code and such a stuff is ok.

A 3D Camera is missing ;-)

No joke - I really more interested to use two Omrons my feeling says to me (if manage to camera value) can be really great!

Boris

PS:

I use for my Moveo Robot - Arm a cool little Mini PC works with WIN10 it´s really fast! You can run with 12V and 2 Amp maybe 4 Amp i forget but 12V!

http://www.orbsmart.com/products/orbsmart-aw-08/

I tried Odroid Xu4 and Rasperry 3B with Ubuntu Linux and they are slowly!

Specialy the Ordoid!

It´s a TIP if someone serach for something like this.

#122  

A good question for the Omron tech support. Maybe they can give you more information? Two eyes are better than one... LOL

#123  

Hi Andy,

you are right!

Mostly two are better then one!

LOL

Boris

PS:

If you can ask - it will be cool!

#124  

I'm taking a stab at updating the plugin David C. made so I can learn more about how it works and update it so it natively works with the Latest Omron demo software so we won't have to do as much manual modification.

One thing that has me scratching my head from the beginning is why we needed to edit the" UserInfo.dat" file after we made a copy of the RegistData folder in the DB folder (that process starts at step 13 to copy the folder and 15 to edit the file in post #104).

The file format did not change between the old version and the new version, it stayed the same, but with out the edit the ARC skill plugin will read the 3rd line of the "UserInfo.dat" file instead of the 2nd line.

I total understand the reason to copy the folder, because the path is hard coded in the plugin and the new version of the EvaluationSoftware stores the data in a different path.

In the source code, in the file Omron_HVC-P.cs, this is the code that deals with actually reading the UserInfo.dat file.


                ///open the UserInfo.dat file
                filepath = filepath + @"\" + longuserid + @"\Userinfo.dat";
                string line = "";
                founduserid = false;
                int linecount = 0;
                using (StreamReader sr = new StreamReader(filepath, Encoding.GetEncoding("windows-1252")))
                {
                    while ((line = sr.ReadLine()) != null)
                    {
                        line = line.Replace('\x0', ' ');
                        line = line.Replace(" ", "");
                        ///check to make sure the first line matches the UserID variable
                        if (line == int.Parse((longuserid)).ToString())
                        {
                            founduserid = true;
                            linecount = 1;
                        }
                        ///Get the value from the second line
                        else if (founduserid && linecount == 3)
                        {
                            linecount = 3;
                            UserName = line;
                            break;
                        }
                        linecount++;
                    }
                }
   
                //}
                
                return UserName;

            }
            catch (Exception ex)
            {
                return "";
            }
        }

The "linecount == 3" puzzles me. The complied plugin works with the old software version. But the file format contains the actual name in line 2 in both the old and new version.

For anyone that can read c# code, any thoughts on how this would work to read the 2nd line in a file? To me it looks like it should always have read the 3rd line.

My assumption is I don't understand what I'm reading because I know David C. and his son know their code!

#125  

HI Justin,

to check out the script.py from David plugin was also my first idea, but i must say i am not good in C+, thats why I was searching in the folders and found the UserInfo.dat.

It will be the best to change the plugin and understand the coder. So we can change the plugin and for the future will be all good. No copy and paste Albums and change UserInfo.

Like Justin said: Everybody who understand C# feel free to pimp the plugin

#126  

Hi to all:

I saw before 5 Minutes a Report in TV about state monitoring in china and they had an interview with a guy from a chinese firm called "face++"

A firm who develope Face Recognition Software.

https://www.faceplusplus.com/

Interesting, but a software solution what will cost each data stream.

And who know where the data goes ;-)

A Hardware Offline Solution is safer!

Boris

#127  

Hi Boris,

Any idea how to run the two Omron cameras ? How would you address (identify one from the other) the wide angle camera versus the normal camera ? How would the separate data return ? (variable)

Ron

#128  

HI Andy,

Still i don´t know - i wait for my second cam - then i will check out.

I am not so lucky that nobody (except we) is interested in the Omron Cam.

So i don´t know - i think the fastest way to repair the plugin to learn yourself C+!

I have read the Treath "I Miss" and they have right! I miss also a forum for more complicated problems - like our Omron Problem!

Or what i really miss: A possibility to save data from EZB to a Excel file or XML file - however but save data!

I was searching in the EZB forum about this problem, but i not find something like that.

Maybe i open a new treath with this question and maybe somebody will answer.

Boris

#129  

Hi Boris,

I am working on an update for the PlugIn, did you not see that? If you and Ron are the only seriously interested Omron users rights now, that's ok, at least there is the 3 of us. What you and Ron can help with are ideas that you want to see in the plugin update revisions.

As far as your 2 Omron cameras idea, I am actually working with an Omron tech and I asked him on your behalf about your idea he said 2 Cameras should be ok if you are considering them separate cameras (which they would be). If you were thinking of daisy chaining them together, that would not work.

The problems you would run into is trying to use the same database files (.hac and UserInfo.dat files); you would need two directories and two identical copies of the files and the .hac file would need loaded in each camera. - That might be tricky. This means ultimately the plugin would need a special modification to allow for multiple installation paths and multiple HVC-P cameras.

#130  

HI Justin!

YOU also here (joke)

Sounds really cool your connection to the Omron tech!

For the two Cameras - My ideas was to have two albums One for the wide and one for the distance!

I want to have two times the same values and then i want to calculate / average the best value for example Emmotion - age or Face Reco.

My idea - with two eyes you can see better ;-)

So i understand this can work!

I wait for the delivery and then i can begin to test.

To the Update:

Great,cool and SUPER! that you work on an update for the Plugin!

And no - i did´nt see that - can i download it from the plugin section - i will check.

And that we can give ideas is awesome and wonderfull! I and i think Ron (Andy) will do that!

You are a cool guy Justin! Thanx for oyu help!

Again Happy Halloween

Boris

#131  

LOL, no I'm not close to finished with any update to the plugin! HAHA I still have a day job too. Maybe in couple of weeks I'll have a rev.1 released. But keep the ideas coming in the mean time.

Happy Halloween!

#132  

Hi Justin!

Ok i was searching and think myself i am blind.... ;-) ok no problem I was waiting so long some days or weeks "Do not make the cabbage more fat"

I am thinking what you said to copy the same album in two folders.

mmmm

Also interesting - Because my idea was to record my face with the wide cam and then with the distance cam. So in this way i have two different albums ( but with the same person - me)

Because my calculation - you can save 10 picutures for a person 8 from different angles)

Two Cameras means 20 Pictures from the same Person .... Must be more reliable for Recognition.

Meanwhile i am writing down some point what will be interesting for the plugin.

Boris

#133  

Right, for a technical solution you can either share the folders and trained faces (the same 10), you can you train 2 different sets (up to 10 faces per user in each set for a total of 20 between the 2 per user).

You or we would probably need to experiment to see which way yields the best results. The Omron tech said to their knowledge no one else is doing that. "....To Boldly Go, where No One Has Gone Before!"

#135  

HI Justin Hi Andy,

Yeahhh, let´s go where no humans where before. ;-)

At the day i got the second cam i will try and post.

Boris

#136  

I am learning a lot about the Omron cameras. Their technical support is fantastic!

1st off, the site Ron found mentioned that the Omron P2 camera could detect pets. This answer is coming straight from Omron "We have Pet Detection but it is not available with HVC-P2. Only for consumer model called HVC-C series but this is already discontinued." No go for pets.

2nd Omron confirmed that the user albums (the UserInfo.dat files) are of a different format between HVC-P and HVC-P2 cameras. So while we can open the files in Notepad and the data appears the same to use, the format is different enough to cause David Cochran's plugin to read the 3rd line of the UserInfo.dat file.

If I use the application NotePad++ to view the files I can see the format of the UserInfo.dat file saved from the v2 software is "UCS-2 LE BOM" formatted. While the v1 software UserInfo.dat files are encoded format "UCS-2 Little Endian".

#137  

Hi Justin,

nice to hear from you!

to 1: (Pets) oki doki forget it, but thanx for the info

to 2: For me it´s ok! It´s takes 5 seconds to change it.

What will be interesting is the twisted values from FaceY to HandX (post #109)

Boris

PS: In the moment i am reading your Tutorial "Reading and Writing with Files" and respect! You made really good Tutorials!

But i am still wondering how i can save for a sepacial "variable" all values what i will get. But first i will read your Tutorial to the end and the we will see.

#138  

Boris, can you re-explain to me what you mean about the twisted values from FaceY and HandX? I'm not sure I understand and I would like to be able to ask the Omron tech for you (and all of us) while I'm actively working with him.

By the way Boris, their software team seems super curious about your 2 camera idea. Apparently they have not heard of anyone else using 2 of them. :)

#139  

Justin and Boris, Just a Hello.

Thanks for your efforts Justin. I am real happy the tech support has responded to the extent they have in answering your questions . I am also pleased they have taken an interest in Boris' idea. Sounds like we have quite an opportunity using this camera.

My work has not let up yet. I hope to be back testing once I get back from the trip, but I will continue to monitor the thread.

Ron

#140  

HI Justin,

LOL why nobody cam on the idea with two cameras?

It´s a normal way of thinking - you have one who is specialist for near things and one is specialist for far awary things - so combinated these two and you will have a specialist what can all!

For the X-Y Problem:

I have a script (Omron_dectect_Options, "r,f,o") - so the camera will dectect faces

Then must get Values for

"Omron_face_CoordX" and "Omron_face_CoordY"

if a face will recognized

BUT

i will get only values for "Omron_face_CoordX"

But funny i will get a value for "Omron_hand_CoordX" so a value for a x-coodinate for a hand.

But i not set in the options to search / recognized Hands

SO i think there is something twisted in the plugin from David

Check out yourself

Search for faces and you must get different values, but no value for Hands.

Hi Andy!

Also "Hello" to you, no Problem i am also @ work but my work is in front of a computer so i can work from time to time on robot stuff.

Boris

#141  

Hi Justin, Hi Andy,

i got for 30 min a phone call from a Omron Salesmen, because i registred befor some weeks for Information Material about Recognition Sensors.

He told me funny story about a Tabletennis Robot also with two (2x) Cameras ;-)

https://www.youtube.com/watch?time_continue=162&v=Bnnyb43II4c

The Robot is the newest Baby from them.

Boris

#142  

Oh Great ! Now Antonn will want arms !

#143  

Hi Justin,

i have study your read and write tutorial

https://synthiam.com/Community/Tutorials/176/1

and i must say i learn a lot from this.

I merge your script with the omron cam/script.

I let the omron check for "Name" and "Age"


:loop

ControlCommand("Omron HVC-P", Omron_Detect_Options, "r,a")

goto(loop)


The i let your writfile script run:




$filename = "c:\meinhirn\myfile.txt"

FileReadClose($filename)
# FileDelete($filename)

$count = 0
$max = 100

:START

print("Writing line " + $count + " of " + $max)



FileWriteline($filename, $Omron_Recognized_Name + "," + $Omron_age)


$count = $count + 1

if ($count = $max)
  halt()
endif

sleep(1000)

goto(START)


OK i let the script write an entrie every second.

This will look like this:

Quote:

Boris,40 Boris,45 Boris,33 Boris,26 Boris,41 Boris,37 Boris,42 Boris,41 Boris,46 Boris,44 Boris,38 Boris,43 Boris,41 Boris,40 ,0 ,0 Boris,24 ,0 Boris,38 Boris,39 Boris,43 Boris,44

Fine!

Now i can read the file like this ( Print only the value for age):


$filename = "c:\meinhirn\myfile.txt"

if (FileExists($filename) = false)
  print("File does not exist")
  Halt()
endif

FileReadReset($filename)



:START

$txt = FileReadLine($filename)

$schnitt = Split($txt, ",", 1)



print($schnitt)

 if (FileReadEnd($filename) = true)
    print("End Of File")
    halt()
  endif



goto(START)


Also fine!

BUT.... now it come to interesting situations:

I have 22 entries (3 without a result or value = 0) ..... so 19 entries with a value

I add all values for the age (745) and divide with the number of entries with result (19)

40+45+33+26+41+37+42+41+46+44+38+43+41+40+24+38+39+43+44= 745

745/19 = 39,210526......

So now i have the average of the age (39)

My problem is i can print the hole line but i CAN´T add the Value for Age.

The second problem is: If there is an entrie / line where is no value or a "0" i can´t count with this.

I hope you understand what i want to make.

Boris

And i hope you can help me.

#144  

Hi Boris,

There is a solution to your question. I can't give you a ready made solution right now because I don't have the time to write you script. But It's very solvable and I'll make a new tutorial specifically for your type of questions when I have time.

As a Hint if you want to try it your self in the mean time here is the basic process you need to incorporate.

You need to add a count function. So you can count your lines.

You need to read each line (which you are doing) but you need to grab the age assign it to a variable then each time you read a line, continue to add the age value to your variable Like $szAGE = $szAGE + ValueFromFile

You also want to increment the line count each time you read a line in the file like $szLineCount = $szLineCount + 1

Then at the end of your script you have to total amount of line read in $szLineCount and you have the sum of all of your ages in $szAGE.

Then you can take those and divide them with the math function in ARC to get your average age value.

#145  

For the 2 camera idea, if you want to share trained faces between the cameras, the Omron support had this to say:

>>It is possible for customer to share album data between 50 degree and 90 degree type. But every time when customer enrolls person to HVC-P2, they have to select camera type and share album date (*I think he meant data) to another HVC-P2. Also, if the 50 degree HVC-P2 uses album data from 90 degree HVC-P2, accuracy might decrease. <<

So that is something to be aware of for anyone want to experiment with 2 cameras.

#146  

Hello Justin!

Time is come!

I got some experiemtents with two omron cameras!

I have learned a lot about the two different versions.

I also made some Boxes for them. (I will post tonight)

I also see you write something new ( i must read now)

(Now i begin not with "I")

And i have a question:

How i can make a copy of David plugin?

I got everything (thats show a second Omron plugin - a second Control Command)

BUT.... The GUID is not working.

I copy a second folder with a "_copy" but if i load the plugin i got a message that the GUID is not valide! Please got a new one from EZ-Robot.

Do you know a solution?

Boris

#147  

HI Justin.

NO it was old. Your Threath I know it.

I will check also the calculation stuff.

But there is still one problem:

What i will do with this lines where i don´t have a Name and a "0"?

In my count function i can´t count this lines!

How i can "leave aside" this lines?

Boris

#148  

Hello Justin!

Forget the plugin!

I made a beta version and i got a new GUID Number!

And it works!

It´s a little bit complicated with the order to connect the cameras to the PC with diffrent COM Ports.

BUT in the END i got TWO Cameras running (not at the same time - this will come)

with diffrent Albums from two diffrent folders ( because of two different albums ;-))

Now i must check how i can rename the variables:

Omron_Face_Recogition

"Omron_Face_Recogition_010"

then i can run this two cameras at the same time.

Then i can write a script:

" IF the Cameras check the age - i will have "Omron_age" and "Omron_age_010"

Now i have twice so much results in 10 seconds for the age and then i can make a calculation for the mid age and it will be perfect.

The same with genger and normal body or face reco.

YOU WILL SEE

Boris

#149  

Hi Justin!

AND HI ANDY!

Sorry i forgot!

OK, back to Omron...

I found the Variables...

in "OmronHVCP_Plugin.dll" ...

i open it with visual 2017 basic but i can´t really find now the variable and i can´t change something.

mmmmm Here i could take a little bit longer.

Or someone an idea?

Boris

#150  

Just got home. Hi Boris....

Two eyes, sounds good. I will be watching......

#151  

HI Andy,

welcome home!

Until now the project goes fast on - i hope it will not stock with the .dll and change the variable names. But i am still on. I must understand how David write the .dll file.

In the end the plugin from David are 4 files (dll, pdb, xml and py ) and the album folder.

The hole rest from the plugin you can delete. The plugin will run without this hole files. But this 4 files the plugin need.

I also manage to make a copy of Davids plugin - so that i can run two Plugins but each as is own.

But later more.

Boris

#152  

Sounds Good Boris. Good luck and thanks for the updates.

Ron

#153  

Hello Boris,

To answer your questions about reading files I updated the Reading and Writing with Files tutorial and if you click on the last step now you will find a link to download the Example Project file which includes the example scripts as well as a link to the training video I made specifically to answer your question because I know it will help others too.

In the project file you'll find 2 new scripts named: ReadFile_Boris and ReadFile_Boris2

And the video that shows how I created the scripts and why.

If you have follow up questions about reading or writing file data, please ask away.

#154  

Boris,

To answer your other questions I have to start by telling you I don't think you understand what those files do. The "Plug In" and everything in there which gets installed when you download the plug in is the finished product - you can't edit and change those. All of those files you mentioned attempting to edit will not help you as they do not contain anything you can edit and there is nothing in there you would want to edit (trust me I know what is in there).

In order to obtain 2 sets of variables for 2 Omron cameras your options are:

  1. use one camera at a time and perhaps store variables to a text file, one file for camera 1 and another file for camera 2 then use the data as needed OR
  2. create a new plug in by going all the way back to the "source code" which David Cochran provided, you can download it from the Plug In page for the Omron Camera, the "source code" link is right above the videos.

However, as you are aware I am already working on revisions including an options for a 2nd camera to create a new plug that I hope to complete before the end of the year, time permitting.

I mention this because if you attempt to modify the source code on your own should know I will not have time to teach you how to program in .NET to create the revision you are seeking.

#155  

Hello Justin!

Your Video is so great and usefull that i am the last 24 hours full busy with scripting!

I will post you my big answer and my hole "thank you saying" later in the night.

i only want to tell you in this moment : That you are great!

More later

Boris

#156  

Hello Justin, Hello Andy,

(and Hello to all other Robot-Fans - Hello Bob Houston, Hello WBS00001, Hello Steve, Hello Richard, Hello fxrtst. .... Hello DJ

Thanx for your hole help and teaching me EZ-Robot Scripts!

Now i want to give something back.

After the really awesome and gigantic help from Justin (Specialy his last Video)

I produce a nice little "Auto-loop-script" for the Omron Camera.

This little Script will ask you (after the Camera recognize a Face with over 700 Points) that you must look 20 seconds to the Cam and the the Robot/PC will guess your age.

This will use also the read and write Script from Justin!

Thanx Justin again for this really great Tutorial!

I add to your last Code a "Round" function - so that you will have hole numbers.



$filename = &quot;c:\meinhirn\myfile.txt&quot;

if (FileExists($filename) = false)
  print(&quot;File does not exist&quot;)
  Halt()
endif

FileReadReset($filename)

$szLineCount = 0
$szAge2 = 0

:START

$txt = FileReadLine($filename)

$szName = Split($txt, &quot;,&quot;, 0)
$szAge = Split($txt, &quot;,&quot;, 1)

if($szAge &gt; 0)
$szAge2 = $szAge2 + $szAge
$szLineCount = $szLineCount + 1
endif 



print($szName)

 if (FileReadEnd($filename) = true)
    print(&quot;End Of File&quot;)
   
    
    goto(END)
  endif

goto(START)

:END


$szAverageAge = $szAge2 / $szLineCount
$szAverageAge = round( $szAverageAge,0 ) 
Print($szName + &quot; is an average age of: &quot; + $szAverageAge)
Say(&quot;You are &quot; + $szAverageAge + &quot; years old.&quot;)
FileReadReset($filename) 
ControlCommand(&quot;Script Manager&quot;, ScriptStart, &quot;Surveillance&quot;)


Also you will find the hole Scripts in the EZ-Robot Cloud.

The Name is "Omron Surveillance Age" - or search for RentaPrinta Member

Here is the direct link:

https://synthiam.com/Community/EZCloud/RobotAppDetails.aspx?id=5220

I will do a upgrade/update over the weekend. That the PC will guess what you are.

A MEN or a WOMEN.

I hope this scripts will help some people with the same problems.

Boris

#157  

Ok, updated plugins for the Omron Camera. This has the updated Omron software in it and works natively with the new database format. I added a couple of simple revisions to David Cochran's original code and included sample ARC projects.

For a single camera HVCP or HVC-P2 model: PlugIn for HVCP

For those 2nd Camera users (I'm looking at you Boris, LOL) PlugIn for HVCP (Second Camera)

Anton and Boris please test when you can and let me know if anything breaks.

Reminder If you had code working with the OLD plugin you'll need to update it to use the NEW plugin because those CommandControl objects are different.

If no bugs are reported I'll do an updated usages video.

#158  

Thanks Justin, I will give it a try tomorrow morning.

Ron

#159  

Hi Justin,

Thanx also from me. I will also test like Andy, tomorrow and i will give feedback.

Boris

#160  

Hi Justin,

so i checked you two plugins and they look that they are working!

The Album is now working - NO CHANING NAMES

The second Camera is working - ALSO SECOND VALUES

GREAT!

Only the FaceX Value is still twisted with the HandX Value

User-inserted image

User-inserted image

I will test again the plugins more deeper today night and i will tell you if i will find another errors.

BUT until now - REALLY COOL! Specialy the second Camera!

THANX, THANX!

Boris

#161  

Hi Boris, thank you for testing! That is exciting to hear my first plugins turned out well so far.

Your results for the values are interesting, I will take a look at that and see if I can find the cause. Thank you again!

#162  

Hi Justin,

no Problem - it´s my job to do that.

But cool, now with 2 Omrom and two Kind of values!

I will test more.

Boris

#163  

HA! Good work Boris, sure enough, there was a typoe in the original source code from David where "hand" was typed in place of "face" for the variable. I want to try to add something else before I release a new update. Before I do....do you have any other ideas you'd like to see added?

#164  

Boris or Anton, does Body or Hand detection ever return anything for you? Either with the Omron Evaluation software or in the variables in ARC?

Mine never detects my hands or body.

#165  

Hello Justin,

i got values from Body and Hand BUT......

User-inserted image

User-inserted image

BUT.....

It not works everytime!

Normaly I must run the Omron original Software and then I can run the plugin in ARC and it works.

The same situation with the Name Reco.

On the next day, I start the computer and plug everything and start first ARC!

MMmmmm no working recognition... so i load the Omron original Software and check that the album is ok. In the Omron Software the Recognition works not everytime... so Ii had a look into my saved Album and then I go back to the video windows and suddenly the Recogition works! Then go to ARC and how wonder there also the Reco works.

And this I do regular!

Funny- its like that the Board must load again the Infos or the the Original Software make the Board load right.

It´s stoopid, but it´s feels like that. I mean it´s not running with the first time- only after i check all in the Omron Software and go then to ARC ok.

But if i plug off and plug in the CAM it can be a problem - Then again the Omron SW and back to ARC.

BUT- this was also before with David original Plugin- so this has nothing to do with your update.

Boris

#166  

Both the plugsins are fixed now for the hand/face coordX value swap. I also added a button on both of them to open the Omron Eval software directly so you don't have to hunt for the plugin folder. I also added a "FRA" only option.

#167  

Hi Justin,

sounds cool!

I will check in some hours and will report you!

Boris

#168  

Hey guys...I know I am a little late to join the party, but here I am!:) I set up the plugin and the camera today, I just had too little time lately to do any robotics, and it might stay that way for some time... But since @JustinRatliff made the magic happen and this threat is still evolving, I hope I can participate and also help testing the plugin!

I will do some further testing in ARC soon...I wanted to do this for quiet some time! This will be a lot of fun!:D

#169  

You are never late @Mickey666Maus to the Omron party, cause an Omron party don't stop!

On a serious note....my Omron is the original HVC-P (the one David Cochran developed the first plug in for....but I have on loan an HVC-P2 for testing. Here is my issue, my P2 unit when I save trained users creates a brand new album folder named HVC-P2 inside the EvaluationSoftware_rev.2.4.1 directory.

That's not the default path from the EvaluationSoftware_rev.2.4.1 software. So I don't know if this is something odd my demo unit doing because it's a demo unit or if everyone's HVC-P2 cameras are going to do that? Because my plugin does not point to that folder.

#170  

Hi Justin,

I am not having any luck with facial recognition either. I didn't dig in to see where the folder is yet, but it does have data which is shown in the album in the demo software.

I hope to be able to work on it for a while tomorrow.

Ron

#171  

I have had some other communication issues. Could you clarify what the Omron.exe button does? When I press it I loose communication with the camera.

#172  

Looks like HVCAlbum.hac holds the USERxxxx (name) data located in the software folder like you said.

#173  

Hey guys...I have set it all up now, but even though my Omron.exe button works and I see myself recognized, I get this message within ARC

Quote:

Omron HVC-P -- There was an error communicating with the Omron Sensor. Please check your settings.

Could this be a problem with the Python path...I thought its all good, I will check once more! The Python installation is responsible for sending the data over to ARC, right?

Cool to get going!:)

User-inserted image

#174  

Quote:

Could you clarify what the Omron.exe button does?
Yes, that is just a shortcut to make it easy to open the exe for training faces.

You can not run both things at the same time, the camera can not communicate with ARC and also the Omron .exe, it is either or. It's just there to make it easier so you don't have to hunt for the plug in folder.

#175  

And to clarify, you can have ARC open, you just can't be polling the camera data and also running the Omron .exe. You can only do one or the other at any given time. The button was added for convenience only.

What I need testers to check is the for a album folder in the plugin directory C:\Users\Public\Documents\EZ-Builder\Plugins\d42aefd8-17e4-470b-ae5a-fabdd747035d\EvaluationSoftware_rev.2.4.1

...and see if the user faces are being created in the folder HVC-P, like they should. Or in a folder named "HVC-P2" which is what my specially marked demo unit is doing.

#176  

Thanks soooo much @JustinRatliff, this was my mistake...for whatever reason I thought the Omron.exe needs to be running to operate the board! Now everything works like a charm...:D

One thing I realized while setting up was, it is only possible if a user follows the instructions pointed out in the original version by @DavidCochran, for example the wiring for the FTDI-Friend and the Python Installation.... So I guess it would be nice to either quote some of the instructions or put some link to the original setup?

Those are just details for me it was all easy since I am pretty used to the E-Robot website...I was just thinking of new users!;)

Thanks a lot for getting this up and running, this is great!:D

Btw my faces are stored properly as they should...

User-inserted image

#177  

Hi Justin, Hello Boris, Hello Mickey

I got everything running. I, like Boris, thought I needed to run the .exe.file to run the prog. With the clarification it is working. It is nice to be able to jump over to check the camera and data.

I am still having no luck with the facial recognition. The original load put the face data in the HVC-P2 folder. I then reloaded everything and saved the data to the HVC-P and tried HVC-P/O folder. Still no name shown. If I go to the camera, the data is shown. I do show the variable in the ARC for accuracy of the facial data, but no name.

I have a script running a loop every 500ms which gives a reasonable refresh.

I can pull out everything again and try to load again.

Ron

P.S Thanks for working on this. It is appreciated.

#178  

Justin,

I found the data in

/EvaluationSoftware_rev.2.4.1/B5T-007001/0/RegisData/000 or /001

(I had made two different faces 10 images in one folder, 5 images in the other.) I did not select any special location to save the data, or change the name of the folder during saving.

Ron

#179  

Justin,

Looking at the files Mickey has I noticed I have two additions, in the software.

B5T-007001 HVCAlbum.hac

The data for facial recog. is in the B5T-007001 folder as I stated in the previous post.

Ron

#180  

Thanks everyone for testing, I appreciate it!

@Mickey666Maus, you are correct, everything is required just like @DavidCochran's original plugin. I'll add more details there to clarify that.

Mikey, which camera do you have the HVC-P (original) or HVC-P2? And what is the model number?

Boris, what camera(s) do you have the HVC-P (original) or HVC-P2 And what is the model number?

Because both of yours are working, which is great! I just want to make sure I know why yours are working.

@Ron, your directory path is really out there in the weeds! You have a HVC-P2 correct? What is your model number?

It is certainly weird behavior, because from a programming standpoint I would assume the album path would be hard coded in the .exe of the Eval software but based on the documentation from Omron it appears the Album folder name comes from the ROM on the camera, which make sense from the results we are seeing now with different folder names.

To fix this I think I need to add a config setting to set the path of the album so it is not hard coded and everyone will have the ability to set their own path.

#181  

It is a B5T 007001-010.

I will dump all the old plugin stuff and try the new. I will let you know what is going on once I'm done.

#182  

Hi Justin,

sorry i had no time to check again, but later (after a meal) i do more testing.

Fot your queastion:

I have the old HVP-P and the new ones

HVC-P2 (010) and HVC-P2 (020) - so all what they produce!

Hello Andy!

Hello Mickey!

Boris

#184  

You are AWESOME Boris! I had started to design boxes for the P2, this will save me a lot of hassle!

#185  

Here is some test results from my cameras:

My Omron Original HVC-P camera range detection for hand is better at about 4 feet. Body it does not detect well or often. 4 foot is also the max range for reliable face detection and it gets better closer I get to the camera with 3ft or less being best results.

My demo Omron HVC-P2 camera could start to detect bodies, hands and faces at around 9.5feet. Body detect was best at 4 feet away or further. Hand detection was best at 3 feet away or further. Face detection was best from 6 feet and closer depending on lighting.

In all of my testing overhead lighting can really negatively impact the sensitivity because of the shadows it can create.

#186  

I reloaded everything and still get the B5T-007001 folder which is where data is stored. I will go in and remove all old stuff and the 1.2 software and what ever else.

#187  

Hi Justin,

if you want i can you give the 123Design files.

There you can move the single pieces, if you want to change something in my design.

So now i make a BIG Test.

hear you later...alligator ;-)

#188  

Ended up with the same issues.

Should I try pulling out any folders or files and Move the data in a specific folder?

My initial need is the Facial Recognition. I will gather data on the info you, Boris and Mickey are working on this afternoon.

Ron

#189  

Boris, Thanks for the enclosure ! It meets my needs perfectly !

Ron

#190  

@Ron, thank you for checking everything. It sounds like you need sit tight for now until I release a new revision with a configurable path for the album path.

I should be able to fix it by the end of next week at the latest if not sooner.

Right now the album path is hard coded in the plugin, which would be fine if the evaluation software treated the album data all the same which I assumed it would because evaluation software in conjunction with the camera is what creates the albums with the trained user faces.

What appears to be happening is based on the particular firmware of the camera the ROM in the camera which is sending back an album path folder which means different cameras will create different albums.

And @Boris, that would be great, I would like to see the 123Design files. Can you send them to my gmail address? You can find my gmail address in my profile.

#191  

HI Justin!

So i had a middle check up!

Everything fine with the plugins!

Fixed: Hand and Face X Cord. now works !

Omron.exe works fine (if the correct COM is selected and the correct Album is copied ;-))

If find out - if you work with two omron cams - My lovly PC gives everytime a different COM Port to the CAM. If i want to have it with out problems or select the right COM Port, i must plug and start all thing like a solder in the army. Exactly in the same order! But this is my problem because i want to use two CAMs

To the Album Path:

It would be nice if the plugin only needs the "B5t...." Folder for the Album and not also the "HVC-P" Folder.

So we can use the "Omron.exe" to start can dcheck the album and the plugin read from the same folder.

Now i must copy it twice.

But i read you are on the way to change it in the new update.

Other Idea:

What do you thing about a LOG file?

Like our Project "Read and write Data"

So i mean an automatic generated txt file where are this infos/data waht i want.

Like to have a option in the plugin ( like a checkmark)

LOG File yes/no Time repeat (how many seconds/minute) which Values

Then you know, i can write a script who reads the data from the file and i can do or the robot can do what we want with the data ;-)

Because the hole idea of the Omron Camera: IS TO HAVE DATA!

It´s a men or woman? It´s me? It´s a human?

SO in the end, i don´t need the Camera, i need the data and the time ;-)

But this is only a Brainstorm

Boris

PS:

I will check now the 123d files. Also to Andy... if you want to change something in the design.....

#193  

HI again,

I wanted to give also some infos about the diffrences of 010 and 020 CAM

the 010 CAM is the Standard one (like in a normal Web CAM)

I must say the picture/video for a distance of 2-3 Meter is like a good webcam. (fast and good video quali.)

For the 020 CAM with the Fisheye..... it´s (my opinion) not so good for this distance.

The 010 is also much faster in recognition then the 020

the 020 is only good for long distances... But a little bit slow (if you know the 010).

I had first the 020 and i was lucky with it.

Then i got the 010 and i think myself the 020 is not so good...

Strange Fisheye visual.. slow recognition.... mmmmm

But this i my opinion.

Boris

#194  

Other info:

A Omron Salesmen told me, that is possible to upgrade the RAM on the Camera.

"1. Where will be mounted the additional RAM to increase the number of registered people? The AM will be mounted on the free space on the PCB"

This will be give more place for more saved users.

But how much cost the RAM, where i can buy it and how it really works.... nobody knows ;-)

#195  

@Boris, for your idea to integrate logging into the plugin, that is firm no.

What we want to remember is that the purpose of the plugin for the Omron is to provide a connection point to the camera into ARC. From there the scripts you develop inside of ARC can do what ever logging you want. None of that needs to be built into a plugin - that would be bad programming design on my part if did that.

I did get confused on what you are coping twice. Can you re-explain what you are copying twice?

Quote:

So we can use the "Omron.exe" to start can dcheck the album and the plugin read from the same folder. Now i must copy it twice.

BTW, thank you for all your other feedback too on your testing of the other cameras!

#196  

HI Justin,

i mean i must copy my album data to the B5T Folder and to the HVC-P Folder

The B5T Folder to run the Omron.exe

and the HVC-P Folder for the plugin

To the logging

never mind - only a brainstrom

#197  

@Boris, can you post a screen shot of your B5T folder so I can see what you are talking about and let me know which Omron camera is doing that?

#198  

Hey guys...sorry for the late reply, I am just too busy on non robot related things. Which is a shame! stress

I just wanted to let you know that I am using the plugin with my one year old Omron, and everything works very good! I will attach my invoice so you can check the version of my camera!:)

Nice clean prints, and tight design @rentaprinta

Cool thing we are having this threat running, my Omron was in the shelf for almost a year, now finally thanks to @JustinRatliff, I took the courage to get it all wired and running....AWESOME!:D

User-inserted image

#199  

@Mickey666Maus, thank you for the positive feedback! I think the Omron cameras really are great.

I'm also glad this thread keeps going. I know Omron owners are out there or new ones might join us as we keep doing more with our cameras.

Back to Ron and Boris's issue with the folders. I wanted to explain the issue again, especially for folks in the future. The problem is the folder album path is hard coded in the plugin and Boris and Ron have different album paths (and I have a different path as well with my Omron demo P2 camera). I need add a new feature in the plugin to make that an adjustable setting.

But why?

User-inserted image

This image is from Omron's command manual. It shows how the album data is communicated between the host (the PC) and the camera in the ROM (Read Only Memory). The ROM firmware communications its own album name. And what we are seeing is even with the HVC-P2 camera the naming convention of the album path is not the same within the same model number of camera, which means either firmware was changed or something.

So in week or when I can when I fix this we can all move past it and forget about it and not worry about it.

But a few of us have aspirations of using the camera for possible production robots and those firmware "gotchas" might be important to know about so if you using it in a production run, make sure your batch from Omron has all the same firmware.

#200  

Hi Justin,

i will check the firmware and i will make you screenshots of the folder.

@mickey: Danke, welche Ausdrucke meinst du?

Boris

#202  

Album path feature is added in the configuration menu of the plugins now. You must set a path.

I also added a "plugin folder" button because I'm always going to the folder and I'm lazy and I wanted a button so you all got a button too.

And I added Question Mark helpers to explain what the buttons are for and to re-iterate multiple time that the camera can NOT communication with both ARC and the Omron evaluation software at the same exact time.

I updated direction in the plugin download webpage too, as an FYI, because the webpage shows more details.

#203  

YOUR THE MAN ! What a nice Christmas gift. Thanks.

Ron

#204  

Hi Justin,

I set up the new plugin and saved a face. Everything is working again except the facial recognition.

The facial data is stored in the B5T-007001 folder in the 0 subfolder. Do I move this data somewhere else or copy it into the HVC-P folder?, also in the 0 subfolder? Do I set a path to the B5T-007001/0 ? As you know I am unsure in this area.

It sounds like I am still in the same situation as I was before the new (4) upgrade, but I know I am getting close.

Ron

#205  

No Ron, you do not need to "move" anything.

Everyone must set the album path in the Configuration settings. That is why the update was released so everyone can set their path now because of variations like yours, if you are not setting your path to your own folder where your actual album is then your face recognition will never work in ARC.

Configuration:

User-inserted image

-You will need to configure for your camera for port, baud, Python folder and album folder for trained user faces. Once you save the configuration your settings will be saved for future use.

Ron your full folder path is probably: C:\Users\Public\Documents\EZ-Builder\Plugins\d42aefd8-17e4-470b-ae5a-fabdd747035d\EvaluationSoftware_rev.2.4.1\B5T-007001\0\RegistData

Here is a picture of my album path, you see the directory path is highlighted in the address bar. My trained user face folder 000, 001, 002 are visible in this folder.

User-inserted image

#206  

Mine isn't working. I will continue to work on it using the info you have shown.

I don't know why my data isn't saving where I want it. I will let you know what is going on when I sort it out.

#207  

You need share screen shots Ron of where your album data is. Where ever your user.dat file (you can see in my screen shot where my master User.dat file is) is saving too, your camera itself picks that when you train user faces in the evaluation software. I think you are just confused on the folder path name.

#208  

I got it running with 3 faces.

The data is stored in the B5T-007001\0 folder.

I guess, like you said, each camera has it's own path for storage.

I had tried to assign the same folder as you did, but it wouldn't save to that location.

Later I may try to dump everything and start from scratch to see if it is ok. For now I want to play with it.

OOPS. I hadn't looked at the screen before I posted to see your message. Yeah, the camera does it's own thing

#209  

That is correct, every Omron camera based on version/firmware might will create its own album path, you can't control that, you just need to know where it is. As long as you know "B5T-007001\0" is you path, and it works for you that is all you need. As long as it is working that is all that maters.

IF it is not working, post or send me screen shots please.

#210  

Actually I previously used a poor choose of verbiage , its the camera firmware in conjunction with the evaluation software that picks the album folder that everyone has no control over.

If your camera is an original Omron HVC-P then you probably get a folder named "HVC-P\0\RegistData"

If you have an HVC-P2 the current version your folder so probably one of these "B5T-007001\0" "B5T-007001\0\RegistData" "HVC-P2\0\RegistData"

#211  

Yep ! That is what I was chasing.

Quick update,

It is so cool to have Antonn tell me who he sees, especially when he says "I see Me."

I plan on programing in Santa Claus' picture, just in case !

Ron

#212  

Hey guys...the new updated version of the plugin seems to be working just fine! But also I do have a problem when running the HVCP_1st_Test_Loop...

When I check on the Omron.exe I can see my name being displayed, but within ARC I am only getting the "I saw no one message"

I am writing my album the the ROM of my Omron camera, is that the correct approach?:)

@rentaprinta Ich meinte die Ausdrucke von Dir auf der Thingiverse Seite!

edit This is the album path that is save in the plugin C:\Users\Public\Documents\EZ-Builder\Plugins\d42aefd8-17e4-470b-ae5a-fabdd747035d\EvaluationSoftware_rev.2.4.1

#213  

Hi Mickey666,

I think your path needs to extend further. I ended up using

\EvaluationSoftware_rev.2.4.1\0

Look at the examples Justin listed. You will probably find the one you need there.

Also you do not need to move anything. The camera firmware and software puts the facial data in the folder location, if I understand Justin correctly.

Ron

#214  

@Mickey666Maus, Ron is correct. That is not your path, it is the start of a default path because something has to be stated in there. That's why keep trying mention over an over that everyone has to set their path.

If I remember Mickey you have an original HVC-P so your full path is like mine which is probably: C:\Users\Public\Documents\EZ-Builder\Plugins\d42aefd8-17e4-470b-ae5a-fabdd747035d\EvaluationSoftware_rev.2.4.1\HVC-P\0\RegistData

#215  

Thanks...I will try that, sorry I did not have enough time on my hands. Otherwise I would have digged thru the thread more thoughtfully! I am positively sure everything will work just fine once I setup the path correctly!

Thanks for the wonderful plugin, and sorry about asking stuff which I should have figured out myself!:)

#216  

@Mickey666Maus no worries. It was good feedback for me to see that having a default path in there can appear confusing. I had to release another update to fix some other issues related to how the variables are treated in ARC so I changed the default path to make it more clear that it must be changed.

Lets all make our bots smarter now with our Omrons. :)

#217  

Antonn says "I see Ron" or "I see Me !" LOL

I cleaned out all the old files and junk. I reloaded the plugin and set up the storage album. I made two scripts one to run the software in a 500 ms loop, the other for speech recognition and all is working well !

Next step is to play a bit, then begin to do more with having responses to the person seen.

I still want to try having faces collected from the tv, which will cause a response. Spock will be the first. I will let you know how I make out.

Ron

#218  

Justin,

Do I have to reload everything again if I update to ver 5, or can I just delete the plugin and load it back into the old project? I will upload the faces in the camera back to the software.

#219  

@Ron, You can delete anything you want, but you don't need to. You should only need click the update plugin inside ARC when there is an update.

In the trouble shooting section of the plugin webpage I mention removing the plugin from your "project" then adding it back if the camera have an hiccup after an update.

I'm sure it is a pain to retrain faces all the time. Loading the faces from the camera back into the software should work or making a copy of the album data before a plugin update then restoring the album folder would work also.

#220  

@JustinRatliff Now I changed the default path and everything works as it should! Thanks a lot for your work and for your patience....I hope I will soon have some time to do some fun stuff with my Omron!:)

@all if you guys are having code to share on how you are operating the Omron, I would be very curious about it...;)

#221  

Hi Mickey,

Load some faces and replace the names with the names you use in the camera.

Some simple code makes a lot of fun. Use the needed prompts and use a 500 ms loop to run the enable script.

Load up a speech recognition script. Question: Who do you see

He will say the name or If no one or just gender is seen he will respond.



if ($Omron_Recognized_Name = &quot;Ron&quot;)

  Say(&quot;I see Ron&quot;)


endif

if ($Omron_Recognized_Name = &quot;Effie&quot;)

  Say(&quot;I see Effie&quot;)


endif

if ($Omron_Recognized_Name = &quot;Me&quot;)

  Say(&quot;I see Me&quot;)


endif

if ($Omron_Recognized_Name = &quot;&quot;)

  Say(&quot;I see No One&quot;)


endif

if ($Omron_Recognized_Name = &quot; &quot; &amp;&amp; $Omron_gender = &quot;Man&quot;)

  Say(&quot;I see a man&quot;)


endif

if ($Omron_Recognized_Name = &quot; &quot; &amp;&amp; $Omron_gender = &quot;woman&quot;)

  Say(&quot;I see a woman&quot;)


endif


Ron

#222  

Hi Guys!

I also want to join again the thread! I was busy the last days!

But i see that the plugin also for you all work!

Great!

@mickey: Ok i was thinking like that (wollte nur mal was auf deutsch fragen/sagen ;-))

You want to have some script for the omron:

no problem, look here:

https://synthiam.com/Community/EZCloud/RobotAppDetails.aspx?id=5220

To this sript i have also a question (maybe Justin can give me an answer)

I want to calculate the diffrences between to dates in hours!

This means:

14.12.2017 23:00 (Start - pm) 15.12.2015 04:00 (End - am)

this are 5 hours difference.

But the cool thing is - the difference is from two days!

I found some calculations to make the difference from dates - but the result are days, not hours!

Have somebody a nice idea?

Best Boris

PS: @ Justin - Nice comment @ thingiverse - thanx

And your plugs working great!

#223  

@AndyRoid Sweet, thanks for sharing, that is a good starting point to mess around!:)

@rentaprinta ( Boris, oder? ) That looks massive, I hope I will be having the time soon to check what you did there! Very cool!

I already noticed there are a couple of Germans, the forum...its really cool we are such an international robotic enthusiasts team! Du kommst aus Berlin oder? Ich wohne in Bremen.... ( You are living in Berlin right? I am located in Bremen... )

Lets keep on having some fun at the Omron Tea Party!:D

#224  

I'm glad the plugin is working well for everyone now. I appreciate everyone's feedback and testing! I was happy to play a part of the team on this. The Omron technical support working with me has been fantastic!

@Boris, looking at your cloud project I don't see anything in your project that relates to logging time/date or using time/date. As it does not relate directly do the Omron camera, I think you should start a new thread for your question on the date/time that way more members are likely to contribute solutions and we can keep this thread focused on the Omron camera.

#225  

Hello Justin,

no not in this project! This project is finish and check the age!

I checked where i saved this time project and i find out that it was not saved.

So i make it again and also a bit easier!

the Script starts with:

"omron Boris spy":



$last_reco_time = $date
$Omron_Recognized_Name = &quot;0&quot;

ControlCommand(&quot;Script Manager&quot;, ScriptStart, &quot;spy_script&quot;)

:loop

ControlCommand(&quot;Omron HVC-P2&quot;, Omron_Detect_Options, &quot;f,r,&quot;)


goto(loop)



"spy_script":


:startspy

if ($Omron_Recognized_Name = &quot;Boris10&quot;)

goto(check)

endif 

goto(startspy)


:check

#the difference of $last_reco_time and $date must be in minutes

if $last_reco_time - $date &lt; 60

$last_reco_time = $date

goto(startspy)


elseif 

$last_reco_time - $date &gt; 60

say(&quot;you went away for 60 minutes&quot;)

$last_reco_time = $date

goto(startspy)


elseif 

$last_reco_time - $date &gt; 120

say(&quot;you went away for 120 minutes&quot;)

$last_reco_time = $date

goto(startspy)


elseif 

$last_reco_time - $date &gt; 600

say(&quot;you slept 10 hours&quot;)

$last_reco_time = $date

goto(startspy)

endif


So i hope this explains more what has this to do with the Omron CAM.

Boris

PS: @mickey

Jau icke komme aus Berlin! (i living in Berlin)

I was last time in Lübeck - maybe next week for one day to Hamburg..... tja Bremen ... long time ago

#226  

Hi Justin, Next time you talk to the Omron rep. Can you ask him if there is a way to not have backgrounds effect the facial recognition? I am finding the recognition doesn't work away from the origional location of the recording. Do I need to fill the frame with only the face and eliminate as much of the background as possible?

Thanks,

Ron

#227  

Hi Andy,

yes you are right!

I also found out to have better different backgrounds to have better recognition.

But i must say i had a album with long hair and after some month i had shorter hair and the recognition works really good. Or i play with my Hand with my Hair and still the Recognition works good!

But I will ask about this. And meanwhile i will produce a album with only white backgrounds and i will check out if this is better then normal pictures.

Boris

#228  

Hi Andy again,

But if you look to the pictures in the saved album, you will see that the CAM will save the Face as big as possible. So the Background is everytime so small/less then possible.

But a test with a white background will be interesting.

Boris

#229  

@Boris,

First you are missing ( and ) around your IF and ELSEIF argument statements, I don't know if that happened in your copy and paste of code or not.

Next issue is your are not understanding or you are forgetting how $date is used in ARC because it is a "String". Strings are a type of variable that can contain words or anything but you can't perform math against a string variable. Look at your $date and $last_reco_time in your variable watcher and you'll see they are cast as STRING as the type.

This means when you attempt to tell ARC or the computer to perform "$last_reco_time - $date > 120" you could just as well try telling the computer to perform "Apple - Michael Jackson > 120" - clearly it makes no sense.

But there are other options avaliable. Look at ARC Script Help and you'll find these: $date $month $year $day $dayName $hour $minute $second $monthName $time

Try this code and see what gets returned in a Variable Watcher and look at the Type of Variable. This will help you see which of these options will be helpful and which will not (Hint, look for the variables types that are Number Type because you can perform math on those.).


$TestDate = $date
$TestMonth = $month
$TestYear = $year
$TestDay = $day
$TestDayName = $dayName
$TestHour = $hour
$TestMinute = $minute
$TestSecond = $second
$TestMonthName = $monthName
$TestTime = $time

Your final problem is your ElseIF logic usage. Take a look again at how you applied it because your robot would always say you were away for 60 minutes and it would never jump down to the other conditions.

#230  

Hi Boris,

Thanks for the info. Let me know how the white background works out.

Ron

#231  

Hi Andy,

i will do that!

Hi Justin,

I know that i can´t make "$date - $last_reco_date"

There is FmtDate and FmtTimeSpan but there i got a problem that my result is not in minutes.

So my question was: Which calculation gives me as a result the differences between two dates in minutes.

Thats not so easy to have only a "Einstein - Formula" and it works.

But thats why i am asking!

Boris

#232  

@Boris, it doesn't sound like you are taking the initiative to do the work, I gave you the variables that you CAN use and a script experiment so you can see what the options do and the types in ARC so you can understand how to use them properly.

You can't take the $date variable string with the time/date stamp in there, but you can use the individual variables: $month $year $day $hour $minute

$second is even optional if you need it for something.

Your first script becomes:


$last_reco_time_month = $month
$last_reco_time_year = $year
$last_reco_time_day = $day
$last_reco_time_hour = $hour
$last_reco_time_minute = $minute

$Omron_Recognized_Name = &quot;0&quot;

ControlCommand(&quot;Script Manager&quot;, ScriptStart, &quot;spy_script&quot;)
:loop
ControlCommand(&quot;Omron HVC-P2&quot;, Omron_Detect_Options, &quot;f,r,&quot;)
goto(loop)

#233  

@Boris, for the second part of your script here is the part of the solution. I don't have time to build your entire script for you.


:startspy

if ($Omron_Recognized_Name = &quot;Boris10&quot;)


goto(check)
endif 
goto(startspy)

:check
#the difference of $last_reco_time and $date must be in minutes

if ($last_reco_time_year = $year AND $last_reco_time_month = $month AND $last_reco_time_day = $day AND $last_reco_time_hour = $hour AND $last_reco_time_minute - $minute &lt; 60)

print(&quot;The time was less than 60.&quot;) #Print  is just for testing 

$last_reco_time_month = $month
$last_reco_time_year = $year
$last_reco_time_day = $day
$last_reco_time_hour = $hour
$last_reco_time_minute = $minute
EndIf
goto(startspy)

That will give you an idea of what you need to do to cover all of your time/date bases. I will recommend again you take this topic and start a new post so you get more input because likely no one else is going to follow the "Omron" thread if they don't have a camera and this is not related to the camera.

There are also other thread topics from other members who have solved the thread date/time script issues which you could search for in old community posts to see other solutions.

#234  

Hi Justin!

Thanx a lot for oyu help!

First i never (i also told this month before) want to have a complete ready solution!

I only want help! And you helped me again!

That why really big thanks to you! Cool Guy!

I found out with your script ideas what was wrong in my thinking!

I was working with the FmtTimeSpan in wrong way, but i found out in your script that i must separate each "part" - so days - hours - minutes

then i can bring everything to minutes (like breack statement from school)

days * 24 (hours) * 60 (Minutes) hours * 60 (Minutes) minutes (haha - no calculation ;-)

Then everything add and then we can compare the minutes with my "IF and ELSE" Statements

Here is the ready code for calculate the difference between to dates and the result is in minutes:

Update: First you must define a variable:

$date2 = $date

To calulate a difference, i change my computer time, then set the $date2, change again the computer time to the actual time and then the script can give you a result.



$tag = FmtTimeSpan(CDateTime($date) - CDateTime($date2), &quot;dd&quot;)
$tagmin = $tag * 24 * 60
print($tag)
print($tagmin)
$stunde = FmtTimeSpan(CDateTime($date) - CDateTime($date2), &quot;hh&quot;)
$stundemin = $stunde * 60
print($stunde)
print($stundemin)
$minutespan = FmtTimeSpan(CDateTime($date) - CDateTime($date2), &quot;mm&quot;)
print($minutespan)
$kpl_zeit = ($tagmin + $stundemin + $minutespan)
print(&quot;The difference is : &quot; + $kpl_zeit + &quot; minutes&quot;)



For Translation i use german words:

tag=day stunde=hour zeit=time

And you see Justin, i don´t need a new Post, you fix this problem wih two answers! Come on, this is great!

Boris

#235  

I will write now the hole script for the omron cam and then i will post the hole script

Boris