esimov / pigo

Fast face detection, pupil/eyes localization and facial landmark points detection library in pure Go.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Feat request : no output, JSON output

jackyhallyday opened this issue · comments

Hi,

I'm starting to use the Pigo command, and while it's pretty good at detecting faces, its usage is a bit weird. Before that, I've tried some other applications like face_detection and facedetect.
Both can output the coordinates of the faces directly to the console (which is pretty useful to retrieve these infos from PHP).
But Pigo forces to create a PNG file (which is useless for what I want to do), and writes the JSON data to output.json in the current directory. If two calls are made in parallel, it could be a problem.

Would it be possible to:

  • make the -out parameter optional?
  • output -json to the console if no file is specified, or to the specified file instead of 'output.json'?

Yes, it's possible. Probably I'll do with pipe commands.

@jackyhallyday I've updated the CLI app with support for pipe commands. Please check the updated readme file and get the latest source code.