Items with no label
Comunicados
FPGA community forums and blogs on community.intel.com are migrating to the new Altera Community and are read-only. For urgent support needs during this transition, please visit the FPGA Design Resources page or contact an Altera Authorized Distributor.
3338 Discussões

How detects face without RGB sensor

idata
Funcionário
3.182 Visualizações

Hi,

I'm trying to do a face analysis with the IR sensor. I've been able to access to the landmark and expression information but when I cover the RGB sensor it doesn't work. Even neither the face detection doesn't work.

Does anyone know how to solve it?

Thanks in advance,

PD: I'm working in c++ with the RS300 sensor.

0 Kudos
1 Solução
idata
Funcionário
1.354 Visualizações

It works!

I forgot add the line " config->ApplyChanges();" at the end.

Thanks for the help!

Ver solução na publicação original

14 Respostas
MartyG
Colaborador honorário III
1.354 Visualizações

I am not sure why you would need to cover the RGB sensor. If you wanted an RGB scan then you would produce an RGB color stream, and if you wanted an IR scan then you would produce an IR stream. Sorry if I'm being dense!

idata
Funcionário
1.354 Visualizações

I want to do the face analysis in night conditions so I can't use the RGB sensor. I know how to stream with the IR sensor but not how to use the SDK to detect the face without the RGB sensor...

However, the app that the SDK provides works fine without the RGB sensor. For that I'm asking how to extract the face information using just the IR sensor.

MartyG
Colaborador honorário III
1.354 Visualizações

So the problem basically is that you need the RGB sensor to be able to see the face but it will not activate because it is too dark to see the face?

Yuneec flight drones equipped with the R200 camera can do night-vision fine, so it must be feasible to see in the dark. The issue is likely that in your particular case, you need a reaction when the face is detected by the camera.

I admit I've looked at many possibilities and I'm stuck. The only thing that comes to mind is Blob Tracking. If the camera sees a general large flat-ish surface area filling its view - it does not have to recognize it as a face, as Blob Tracking is not that sophisticated - then it may trigger.

idata
Funcionário
1.354 Visualizações

No, I'm able to see the face without the RGB sensor, just with the IR camera, but I don't know how actívate the SDK functions for that as the same way that I do with the RGB.

MartyG
Colaborador honorário III
1.354 Visualizações

RealSense can analyze a person's pulse through IR. The scripts included in this guide may give you some useful clues.

https://software.intel.com/en-us/articles/pulse-detection-with-intel-realsense-technology RealSense - Pulse Detection with Intel® RealSense™ Technology | Intel® Software

You could maybe even use that scripting directly as your face activator. If pulse > 0 then there is a living person in front of the camera.

idata
Funcionário
1.354 Visualizações

It doesn't work the pulse detection, I don't know why

MartyG
Colaborador honorário III
1.354 Visualizações

If you cannot get pulse detection to work, another feature you could try is Person Tracking - tracking body movement.

https://software.intel.com/sites/landingpage/realsense/camera-sdk/v1.1/documentation/html/index.html?doc_pt_tracking_body_movement.html Intel® RealSense™ SDK 2016 R2 Documentation

idata
Funcionário
1.354 Visualizações

This is my code:

int main()

 

{

 

PXCSenseManager *psm = PXCSenseManager::CreateInstance();

 

int sts = psm->EnableFace();

SampleReader* reader = SampleReader::Activate(psm);

 

UtilRender *renderIR = new UtilRender(L"3D IR STREAM");

 

reader->EnableStream(StreamType::STREAM_TYPE_IR, 640, 480);

PXCFaceModule* faceAnalyzer = psm->QueryFace();

 

FaceData* outputData = faceAnalyzer->CreateOutput();

 

FaceConfiguration* config = faceAnalyzer->CreateActiveConfiguration();

 

config->SetTrackingMode(FaceConfiguration::TrackingModeType::FACE_MODE_IR);

 

config->QueryPulse();

// Enable face tracking

 

FaceModule *face = FaceModule::Activate(psm);

 

FaceData *data = face->CreateOutput();

 

 

psm->Init();

PXCImage *irIm;

while (psm->AcquireFrame(true) >= Status::STATUS_NO_ERROR)

 

{

 

data->Update();

cout << data->QueryNumberOfDetectedFaces();

}

 

 

return 0;

 

}

If I cover the RGB sensor, QueryNumberOfDetectedFaces returns 0... So I don't know why or what I'm doing wrong...

idata
Funcionário
1.354 Visualizações

 

Hi MQMQ,

Thanks for your interest in the Intel Realsense Platform.

Did you try MartyG suggestion to use the Person Tracking? If you did could you be so kind to share your results.

Also the code you share in your previous reply, was this created by you? Or are you using an example?

I will be waiting for your reply, have a great day!

Best Regards,

 

-Jose P.

 

idata
Funcionário
1.354 Visualizações

Hi,

Yes I tried the example of MartyG, but it didn't work. The code that I put was writed by me with the help of the Intel tutorial. (/RSSDK/doc/PDF/sdkmanual-face.pdf)

Thanks for answering

MartyG
Colaborador honorário III
1.354 Visualizações

This reminds me of a forum discussion I was working on at the weekend, where people could not get Person Tracking to work with their R200.

Because development on R200 features in the SDK stopped after the 2016 R2 SDK, it is unlikely that the problem will be fixed now if it cannot be done without creating new code.

idata
Funcionário
1.355 Visualizações

It works!

I forgot add the line " config->ApplyChanges();" at the end.

Thanks for the help!

MartyG
Colaborador honorário III
1.354 Visualizações

Great news, MQMQ! Good luck!

idata
Funcionário
1.354 Visualizações

Hi MQMQ,

 

 

I'm glad to know that you got your code running! Please let us know if you have any more questions.

 

 

Have a nice day!

 

 

Best Regards,

 

-Jose P.
Responder