From: Roger L. <ro...@wo...> - 2018-12-17 12:55:03
|
Hi Jon, Thanks for that. I will check it out. Roger. Sent from my Samsung Galaxy smartphone. -------- Original message -------- From: "Hare J.S." <js...@ec...> Date: 17/12/18 22:07 (GMT+12:00) To: Roger Littin <ro...@wo...> Cc: ope...@li... Subject: Re: [Openimaj-discuss] Compile and runtime dependencies for Faces module. Have a look here for a pom.xml file that has dependencies and exclusions for just the things required for face detection on a video stream: https://github.com/jonhare/SimpleFaceDetector/blob/master/pom.xml You’ll have to convert that to gradle format, but I don’t think that should be difficult. You should also be able to remove the core-video-capture dependency. Jon On 17 Dec 2018, at 00:17, Roger Littin <ro...@wo...<mailto:ro...@wo...>> wrote: Hi, I want to put together a face detection example that takes a source video that are streamed to Wowza Streaming Engine and outputs the video with an overlay that draws a rectangle around each face. Because Wowza Streaming engine already has transcoding capabilities, I want to use this where possible. Using the Wowza transcoder Thumbnailer api and Wowza transcoder Overlay api, I can extract the raw video frames in a 4 byte per pixel BGRA format and then apply overlays later in the process using the same format. My plan is to extract the frame data then convert it to an FImage and pass that into the detector and then using the resulting list of detected faces, create an overlay rectangle for each face to add to the output video. The code I’m using is pretty straight forward but when I go to try and build the project, I’m getting a bunch of failed dependencies for quite a few third-party packages that don’t seem to be related in any way to what I’m trying to do. I’m using Gradle rather than Maven because it is a lot easier to integrate Wowza with Gradle, however I get the same result with a Maven project, that just includes the faces module as a dependency. If I try to build the project manually in eclipse, then it does compile ok, so it appears to be finding what it needs to. The problem seems to be with the package managers wanting to try and resolve all of these extra dependencies. I guess the question is, what actual jar files are required for compiling my project and at runtime? It appears that, even though my class only has 5 openimaj imports, the package manages seem to think it’s necessary to include over 140 jar files in the class path. I realise that face detection is a fairly intense process, but this does seem like a bit of an overkill. Below is a snippet of the code I’m using. FaceDetector<DetectedFace,FImage> fd = new HaarCascadeDetector(40); : : FImage fImage = getNextImage(frameCount); List<DetectedFace> faces = fd.detectFaces(fImage); for(DetectedFace face : faces) { Rectangle rect = face.getBounds(); addOverlay(frameCount, rect.x, rect.y, rect.width, rect.height); } Thanks, Roger. _______________________________________________ openimaj-discuss mailing list ope...@li...<mailto:ope...@li...> https://emea01.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.sourceforge.net%2Flists%2Flistinfo%2Fopenimaj-discuss&data=01%7C01%7Cjsh2%40ecs.soton.ac.uk%7C49d4787890964f8146c908d663ca9fa9%7C4a5378f929f44d3ebe89669d03ada9d8%7C1&sdata=7c02XBqnCispvnB1EccujKOKxKJ%2Bs2fJCncOe8OGb54%3D&reserved=0 |