Detect fire in a fire pit (compare)

Discuss digital image processing techniques and algorithms. We encourage its application to ImageMagick but you can discuss any software solutions here.
Post Reply
HDNetCams
Posts: 1
Joined: 2019-04-20T07:07:33-07:00
Authentication code: 1152

Detect fire in a fire pit (compare)

Post by HDNetCams »

I have a request to send a notification when there are fires burning at a resort. The images would be from IP cameras on an interval of say every 5 minutes. It seems to me I should be able to compare the new image with the previous one and determine if there is a dramatic change in brightness in the area of the image where the fire pit is.

Any thoughts? Haven't tried it yet btw, hoping someone could steer me in the right direction.


Before fire
https://drive.google.com/open?id=1JMKCB ... Yt5_tI4HMc

Fire Burning
https://drive.google.com/open?id=1boI-4 ... NNhIniBS17
snibgo
Posts: 12159
Joined: 2010-01-23T23:01:33-07:00
Authentication code: 1151
Location: England, UK

Re: Detect fire in a fire pit (compare)

Post by snibgo »

What version of IM, on what platform? I'll assume IM v7, on Windows BAT.

Code: Select all

%IMG7%magick ^
  "Bldg 2 Fire Pit_2019-Apr-19_20_42_27.png" ^
  "Bldg 2 Fire Pit_2019-Apr-19_20_44_51.png" ^
  -crop 17x11+1301+782 ^
  -format %%[fx:mean]\n ^
  info:

0.372995
0.994118
I've cropped a small area from both images, and found the average pixel values within those areas. There is a clear difference.

Your filenames have spaces, so they need to be quoted. I suggest you name files without spaces, because they are a pain.
snibgo's IM pages: im.snibgo.com
Post Reply