Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Detect cattle in drone video footage

I’m looking at using OpenCV to detect cattle within footage taken from a drone.

Every time I get to the point of making a decision on what technique I should use I either read something contradictory that indicates that it might be a bad choice or I read about some other technique which seems more suitable.
My current feeling is that I should use a LBP Cascade Classifier, but every time I learn something new about it I realise that there’s dozens of other things I don’t know about it or don’t understand fully. And, case in point, just seconds ago I read that HAAR and LBP might not be as suitable for non-rigid objects as some other techniques.
So, while I realise that there will be no ‘right’ answer or silver bullet, I’m looking for some guidance to narrow down the set of techniques I that I should be looking into more deeply.

My initial requirement is to be able to process footage taken from a drone that has crisscrossed a paddock (field) and identify the specific parts of the footage that contain cattle. This information can then be used to create index points (chapters) in the video so that skipping to the next ‘interesting’ piece of footage is simple. Ideally I'd also be able to display an identifying box around the detected cattle.
Initially we can assume that there will not be any other animals, such as horses or sheep, present in the footage or if there are other animals we don’t mind them being detected as well. In an ideal world it’d be nice to be able to tell the difference between a horse and a cow, but for now that’s not a requirement.
The footage of the paddocks will generally be free of other cattle shaped objects, but it will contain trees, logs and rocky outcrops. There will also possibly be sheds, houses, fences and vehicles contained within the footage as well as varying shadows and different shades of grass you would expect to find in such footage.

Most questions/answers that I see about detecting animals (or non-uniform objects) in video footage are about fixed surveillance type camera footage where the background doesn’t change except for gradual lighting changes and most could be solved with simple motion detection. Obviously footage taken from a continually moving camera on a drone will have different problems to content with. The background will be constantly changing and also, because of the camera movement, cattle will not always be placed in one particular area of the frame, nor will they ever track along the same/similar path. Another issue is that I need to identify “cattle”, not “a cow that has has been nicely framed for a picture". Cattle move about in groups and the footage will rarely contain a full clean image of any individual animal, rather there will be animals obscuring each other and animals could be at (almost) any given angle.

Video will be either 720p (or maybe 1080p) at 30fps, but can easily be scaled down as required.

In the future it’d be nice to use a similar technique to detect these regions of interest in real time and once detected have the drone circle them for a given period of time, but that’s a far future enhancement that might require an entirely different technique (and perhaps thermal imaging would be a better solution).
For now we can assume that the video will be processed on a modern PC and that it will be post-processed so it does not have to perform in real time.

Has anyone done anything similar or can anyone offer any advice on a good technique (or several techniques) to get started?

Detect cattle in drone video footage

I’m looking at using OpenCV to detect cattle within footage taken from a drone.

Every time I get to the point of making a decision on what technique I should use I either read something contradictory that indicates that it might be a bad choice or I read about some other technique which seems more suitable.
My current feeling is that I should use a LBP Cascade Classifier, but every time I learn something new about it I realise that there’s dozens of other things I don’t know about it or don’t understand fully. And, case in point, just seconds ago I read that HAAR and LBP might not be as suitable for non-rigid objects as some other techniques.
So, while I realise that there will be no ‘right’ answer or silver bullet, I’m looking for some guidance to narrow down the set of techniques I that I should be looking into more deeply.

My initial requirement is to be able to process footage taken from a drone that has crisscrossed a paddock (field) and identify the specific parts of the footage that contain cattle. This information can then be used to create index points (chapters) in the video so that skipping to the next ‘interesting’ piece of footage is simple. Ideally I'd also be able to display an identifying box around the detected cattle.
Initially we can assume that there will not be any other animals, such as horses or sheep, present in the footage or if there are other animals we don’t mind them being detected as well. In an ideal world it’d be nice to be able to tell the difference between a horse and a cow, but for now that’s not a requirement.
The footage of the paddocks will generally be free of other cattle shaped objects, but it will contain trees, logs and rocky outcrops. There will also possibly be sheds, houses, fences and vehicles contained within the footage as well as varying shadows and different shades of grass you would expect to find in such footage.

Most questions/answers that I see about detecting animals (or non-uniform objects) in video footage are about fixed surveillance type camera footage where the background doesn’t change except for gradual lighting changes and most could be solved with simple motion detection. Obviously footage taken from a continually moving camera on a drone will have different problems to content with. The background will be constantly changing and also, because of the camera movement, cattle will not always be placed in one particular area of the frame, nor will they ever track along the same/similar path. Another issue is that I need to identify “cattle”, not “a cow that has has been nicely framed for a picture". Cattle move about in groups and the footage will rarely contain a full clean image of any individual animal, rather there will be animals obscuring each other and animals could be at (almost) any given angle.

Video will be either 720p (or maybe 1080p) at 30fps, but can easily be scaled down as required.

In the future it’d be nice to use a similar technique to detect these regions of interest in real time and once detected have the drone circle them for a given period of time, but that’s a far future enhancement that might require an entirely different technique (and perhaps thermal imaging would be a better solution).
For now we can assume that the video will be processed on a modern PC and that it will be post-processed so it does not have to perform in real time.

Has anyone done anything similar or can anyone offer any advice on a good technique (or several techniques) to get started?

I don't have any footage that is publicly available at the moment, but this footage on youtube, which is not mine and I do not own the rights to it, is a reasonably good representation of what would be available

Detect cattle in drone video footage

I’m looking at using OpenCV to detect cattle within footage taken from a drone.

Every time I get to the point of making a decision on what technique I should use I either read something contradictory that indicates that it might be a bad choice or I read about some other technique which seems more suitable.
My current feeling is that I should use a LBP Cascade Classifier, but every time I learn something new about it I realise that there’s dozens of other things I don’t know about it or don’t understand fully. And, case in point, just seconds ago I read that HAAR and LBP might not be as suitable for non-rigid objects as some other techniques.
So, while I realise that there will be no ‘right’ answer or silver bullet, I’m looking for some guidance to narrow down the set of techniques I that I should be looking into more deeply.

My initial requirement is to be able to process footage taken from a drone that has crisscrossed a paddock (field) and identify the specific parts of the footage that contain cattle. This information can then be used to create index points (chapters) in the video so that skipping to the next ‘interesting’ piece of footage is simple. Ideally I'd also be able to display an identifying box around the detected cattle.
Initially we can assume that there will not be any other animals, such as horses or sheep, present in the footage or if there are other animals we don’t mind them being detected as well. In an ideal world it’d be nice to be able to tell the difference between a horse and a cow, but for now that’s not a requirement.
The footage of the paddocks will generally be free of other cattle shaped objects, but it will contain trees, logs and rocky outcrops. There will also possibly be sheds, houses, fences and vehicles contained within the footage as well as varying shadows and different shades of grass you would expect to find in such footage.

Most questions/answers that I see about detecting animals (or non-uniform objects) in video footage are about fixed surveillance type camera footage where the background doesn’t change except for gradual lighting changes and most could be solved with simple motion detection. Obviously footage taken from a continually moving camera on a drone will have different problems to content with. The background will be constantly changing and also, because of the camera movement, cattle will not always be placed in one particular area of the frame, nor will they ever track along the same/similar path. Another issue is that I need to identify “cattle”, not “a cow that has has been nicely framed for a picture". Cattle move about in groups and the footage will rarely contain a full clean image of any individual animal, rather there will be animals obscuring each other and animals could be at (almost) any given angle.

Video will be either 720p (or maybe 1080p) at 30fps, but can easily be scaled down as required.

In the future it’d be nice to use a similar technique to detect these regions of interest in real time and once detected have the drone circle them for a given period of time, but that’s a far future enhancement that might require an entirely different technique (and perhaps thermal imaging would be a better solution).
For now we can assume that the video will be processed on a modern PC and that it will be post-processed so it does not have to perform in real time.

Has anyone done anything similar or can anyone offer any advice on a good technique (or several techniques) to get started?

I don't have any footage that is publicly available at the moment, but this footage on youtube, which is not mine and I do not own the rights to it, is a reasonably good representation of what would be available available.
And because video is large, here's a single sample image: image description
It's not worst case scenario, but its potentially challenging.

Detect cattle in drone video footage

I’m looking at using OpenCV to detect cattle within footage taken from a drone.

Every time I get to the point of making a decision on what technique I should use I either read something contradictory that indicates that it might be a bad choice or I read about some other technique which seems more suitable.
My current feeling is that I should use a LBP Cascade Classifier, but every time I learn something new about it I realise that there’s dozens of other things I don’t know about it or don’t understand fully. And, case in point, just seconds ago I read that HAAR and LBP might not be as suitable for non-rigid objects as some other techniques.
So, while I realise that there will be no ‘right’ answer or silver bullet, I’m looking for some guidance to narrow down the set of techniques I that I should be looking into more deeply.

My initial requirement is to be able to process footage taken from a drone that has crisscrossed a paddock (field) and identify the specific parts of the footage that contain cattle. This information can then be used to create index points (chapters) in the video so that skipping to the next ‘interesting’ piece of footage is simple. Ideally I'd also be able to display an identifying box around the detected cattle.
Initially we can assume that there will not be any other animals, such as horses or sheep, present in the footage or if there are other animals we don’t mind them being detected as well. In an ideal world it’d be nice to be able to tell the difference between a horse and a cow, but for now that’s not a requirement.
The footage of the paddocks will generally be free of other cattle shaped objects, but it will contain trees, logs and rocky outcrops. There will also possibly be sheds, houses, fences and vehicles contained within the footage as well as varying shadows and different shades of grass you would expect to find in such footage.

Most questions/answers that I see about detecting animals (or non-uniform objects) in video footage are about fixed surveillance type camera footage where the background doesn’t change except for gradual lighting changes and most could be solved with simple motion detection. Obviously footage taken from a continually moving camera on a drone will have different problems to content with. The background will be constantly changing and also, because of the camera movement, cattle will not always be placed in one particular area of the frame, nor will they ever track along the same/similar path. Another issue is that I need to identify “cattle”, not “a cow that has has been nicely framed for a picture". Cattle move about in groups and the footage will rarely contain a full clean image of any individual animal, rather there will be animals obscuring each other and animals could be at (almost) any given angle.

Video will be either 720p (or maybe 1080p) at 30fps, but can easily be scaled down as required.

In the future it’d be nice to use a similar technique to detect these regions of interest in real time and once detected have the drone circle them for a given period of time, but that’s a far future enhancement that might require an entirely different technique (and perhaps thermal imaging would be a better solution).
For now we can assume that the video will be processed on a modern PC and that it will be post-processed so it does not have to perform in real time.

Has anyone done anything similar or can anyone offer any advice on a good technique (or several techniques) to get started?

I don't have any footage that is publicly available at the moment, but this footage on youtube, which is not mine and I do not own the rights to it, is a reasonably good representation of what would be available.
And because video is large, here's a single sample image: image description
It's not worst case scenario, but its potentially challenging.