Send Motion-user mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
https://lists.sourceforge.net/lists/listinfo/motion-user
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Motion-user digest..."
Today's Topics:
1. Re: Motion 4.2.2 vs 4.1.1 CPU usage (rmbusy)
2. Re: Motion 4.2.2 vs 4.1.1 CPU usage (rmbusy)
3. Re: Threshold_maximum (Thomas Drebert)
4. Re: Motion 4.2.2 vs 4.1.1 CPU usage (tosiara)
----------------------------------------------------------------------
Message: 1
Date: Fri, 19 Jul 2019 09:08:04 -0700
From: rmbusy <[email protected]>
To: [email protected]
Subject: Re: [Motion-user] Motion 4.2.2 vs 4.1.1 CPU usage
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8; format=flowed
OS is Linux (before, Ubuntu Xenial 16.04 LTS, now Ubuntu Bionic 18.04.2
LTS).? In both cases, I built motion from source.? I started by
installing the package with apt-get install motion to get all the
dependencies, then built from source and switched to it.
Since there are really only 3 types / configurations of cameras, I only
tested the 3 types.? I watched the output of 'top' for about a minute
for each test.? I also waited for the initial startup to settle (time
for camera to respond with images) before recording the numbers.? I
don't have 4.1.1 building yet, so these numbers are for 4.2.2.
For the 2MP snapshot camera, after startup, before connecting to the web
page, it hovered between 25% and 45% CPU usage.
After starting the web page, the numbers hovered between 78.5% and 81.5%.
For the 1MP streaming camera (5 frames / sec), it hovered between 23%
and 33%.
After starting the web page, 33.7% to 45.9%.
For the 2MP streaming camera (5 frames / sec), it hovered between 42%
and 53.6%.
After starting the web page, 63.6% and 70.3%.
I'm a little surprised no one had usage numbers between the two
versions.? Considering I'm using the same configuration files (with
updates for the new parameter names in 4.2), I was expecting others
would see this problem.? It's an issue for me, because I have more
cameras I want to add, but at this point with 4.2.2, the CPU is maxed out.
--
Rob.
On 7/18/19 11:12 PM, tosiara wrote:
> Could you compare CPU numbers running only one camera? The best to
> make 8 separate tests with each camera. This could help to understand
> the issue better
> Also, which OS are were you using before and now, and which motion
> version - binary package or compiled yourself?
>
> On Thu, Jul 18, 2019 at 9:33 PM rmbusy <[email protected]> wrote:
>> I upgraded my system to the latest version of Linux, and at the same
>> time, upgraded Motion from 4.1.1 to 4.2.2.
>>
>> I have 8 RTSP cameras set up, 5 cameras configured for snapshot mode at
>> 1 frame per second (all 2MP), and 3 streaming at 5 frames per second (2
>> 2MP, 1 1MP). All of this is running on a quad core Rock64 w/ 4GB DRAM,
>> at the default CPU frequency (1.3GHz).
>>
>> With 4.1.1, I was seeing around 150% CPU utilization (via top), and when
>> connecting to the web page, around 300% CPU utilization. Since the
>> Rock64 is a quad core ARM processor, max is 400%.
>>
>> Now with 4.2.2 and the same camera configuration files (updated with new
>> option names), I'm seeing CPU utilization of 250%, and when connecting
>> to the web page, the numbers are maxed out, and the web page is
>> basically non-responsive.
>>
>> Since I upgraded the underlying OS, I can't rule out that it's requiring
>> more CPU cycles for Motion to do the same thing, but that seems
>> unlikely. Running top doesn't show anything else using CPU cycles
>> (other than top).
>>
>> Can anyone confirm if 4.2.2 is using significantly more CPU cycles than
>> 4.1.1? If I can't find a way to reduce the usage, I may have to go back
>> to 4.1.1.
>>
>> Any suggestions would be appreciated.
>>
>>
>> --
>> Rob.
>>
>>
>>
>>
>> _______________________________________________
>> Motion-user mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/motion-user
>> https://motion-project.github.io/
>>
>> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
>
> _______________________________________________
> Motion-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/motion-user
> https://motion-project.github.io/
>
> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
------------------------------
Message: 2
Date: Fri, 19 Jul 2019 09:16:03 -0700
From: rmbusy <[email protected]>
To: [email protected]
Subject: Re: [Motion-user] Motion 4.2.2 vs 4.1.1 CPU usage
Message-ID: <[email protected]>
Content-Type: text/plain; charset=utf-8; format=flowed
One other thing, in an attempt to reduce CPU usage, I've disabled
auto_tune, and added mask files to 5 of the cameras to mask out foliage
and areas that could cause excess triggering, and bumped the threshold
from 5,000 to 10,000 on all of the 2MP cameras.? These changes were not
needed with 4.1.1.
I've also noticed a lot more motion detection of changing shadows,
compared to what I used to see.
--
Rob.
On 7/19/19 9:08 AM, rmbusy wrote:
> OS is Linux (before, Ubuntu Xenial 16.04 LTS, now Ubuntu Bionic
> 18.04.2 LTS).? In both cases, I built motion from source.? I started
> by installing the package with apt-get install motion to get all the
> dependencies, then built from source and switched to it.
>
> Since there are really only 3 types / configurations of cameras, I
> only tested the 3 types.? I watched the output of 'top' for about a
> minute for each test.? I also waited for the initial startup to settle
> (time for camera to respond with images) before recording the
> numbers.? I don't have 4.1.1 building yet, so these numbers are for
> 4.2.2.
>
> For the 2MP snapshot camera, after startup, before connecting to the
> web page, it hovered between 25% and 45% CPU usage.
> After starting the web page, the numbers hovered between 78.5% and 81.5%.
>
> For the 1MP streaming camera (5 frames / sec), it hovered between 23%
> and 33%.
> After starting the web page, 33.7% to 45.9%.
>
> For the 2MP streaming camera (5 frames / sec), it hovered between 42%
> and 53.6%.
> After starting the web page, 63.6% and 70.3%.
>
> I'm a little surprised no one had usage numbers between the two
> versions.? Considering I'm using the same configuration files (with
> updates for the new parameter names in 4.2), I was expecting others
> would see this problem.? It's an issue for me, because I have more
> cameras I want to add, but at this point with 4.2.2, the CPU is maxed
> out.
>
>
> --
> Rob.
>
>
> On 7/18/19 11:12 PM, tosiara wrote:
>> Could you compare CPU numbers running only one camera? The best to
>> make 8 separate tests with each camera. This could help to understand
>> the issue better
>> Also, which OS are were you using before and now, and which motion
>> version - binary package or compiled yourself?
>>
>> On Thu, Jul 18, 2019 at 9:33 PM rmbusy <[email protected]> wrote:
>>> I upgraded my system to the latest version of Linux, and at the same
>>> time, upgraded Motion from 4.1.1 to 4.2.2.
>>>
>>> I have 8 RTSP cameras set up, 5 cameras configured for snapshot mode at
>>> 1 frame per second (all 2MP), and 3 streaming at 5 frames per second (2
>>> 2MP, 1 1MP).? All of this is running on a quad core Rock64 w/ 4GB DRAM,
>>> at the default CPU frequency (1.3GHz).
>>>
>>> With 4.1.1, I was seeing around 150% CPU utilization (via top), and
>>> when
>>> connecting to the web page, around 300% CPU utilization. Since the
>>> Rock64 is a quad core ARM processor, max is 400%.
>>>
>>> Now with 4.2.2 and the same camera configuration files (updated with
>>> new
>>> option names), I'm seeing CPU utilization of 250%, and when connecting
>>> to the web page, the numbers are maxed out, and the web page is
>>> basically non-responsive.
>>>
>>> Since I upgraded the underlying OS, I can't rule out that it's
>>> requiring
>>> more CPU cycles for Motion to do the same thing, but that seems
>>> unlikely.? Running top doesn't show anything else using CPU cycles
>>> (other than top).
>>>
>>> Can anyone confirm if 4.2.2 is using significantly more CPU cycles than
>>> 4.1.1?? If I can't find a way to reduce the usage, I may have to go
>>> back
>>> to 4.1.1.
>>>
>>> Any suggestions would be appreciated.
>>>
>>>
>>> --
>>> Rob.
>>>
>>>
>>>
>>>
>>> _______________________________________________
>>> Motion-user mailing list
>>> [email protected]
>>> https://lists.sourceforge.net/lists/listinfo/motion-user
>>> https://motion-project.github.io/
>>>
>>> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
>>
>> _______________________________________________
>> Motion-user mailing list
>> [email protected]
>> https://lists.sourceforge.net/lists/listinfo/motion-user
>> https://motion-project.github.io/
>>
>> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
>
------------------------------
Message: 3
Date: Fri, 19 Jul 2019 18:17:09 +0200
From: Thomas Drebert <[email protected]>
To: Motion discussion list <[email protected]>
Subject: Re: [Motion-user] Threshold_maximum
Message-ID:
<CANn+32jQ2SX9i-MayPiU6K5uP-U=TzifObvwBP70SPo5XJs=r...@mail.gmail.com>
Content-Type: text/plain; charset="UTF-8"
Hello,
it does not matter if the option is not in the configuration yet, you
can just paste it.
regards
ThomasD
Am Fr., 19. Juli 2019 um 16:08 Uhr schrieb Travis44 via Motion-user
<[email protected]>:
>
> I would love to set a threshold maximum but I don't see the option. I'm
> using a raspberry pi. The config file says...# This config file was generated
> by motion 4.0.1
> Is "threshold_maximum" not a option for the pi?
> Thank you,
> Travis
>
>
> Sent with ProtonMail Secure Email.
>
> _______________________________________________
> Motion-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/motion-user
> https://motion-project.github.io/
>
> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
------------------------------
Message: 4
Date: Fri, 19 Jul 2019 20:35:26 +0300
From: tosiara <[email protected]>
To: Motion discussion list <[email protected]>
Subject: Re: [Motion-user] Motion 4.2.2 vs 4.1.1 CPU usage
Message-ID:
<cachtdwqe9q3wmhrhbkywmvdcrst1mkpfedo6bbh0kzu+byf...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"
This is my ARM board CPU usage over the previous year:
[image: image.png]
It is using USB webcam. In 2018 I changed pixel format from MJPEG to RAW
and it decreased the CPU usage from ~65% to ~35%. In the middle on 2018 I
merged NEON optimizations which saved even more CPU - to ~23%. I constantly
update my motion to master branch, but since 2018 CPU usage on this ARM
device has not changed
So I doubt your issue is in motion's code. It could be compile flags. If
want to be sure, try profiling motion and compare:
http://www.lavrsen.dk/foswiki/bin/view/Motion/MotionProfiling
On Fri, Jul 19, 2019 at 7:16 PM rmbusy <[email protected]> wrote:
> One other thing, in an attempt to reduce CPU usage, I've disabled
> auto_tune, and added mask files to 5 of the cameras to mask out foliage
> and areas that could cause excess triggering, and bumped the threshold
> from 5,000 to 10,000 on all of the 2MP cameras. These changes were not
> needed with 4.1.1.
>
> I've also noticed a lot more motion detection of changing shadows,
> compared to what I used to see.
>
>
> --
> Rob.
>
>
> On 7/19/19 9:08 AM, rmbusy wrote:
> > OS is Linux (before, Ubuntu Xenial 16.04 LTS, now Ubuntu Bionic
> > 18.04.2 LTS). In both cases, I built motion from source. I started
> > by installing the package with apt-get install motion to get all the
> > dependencies, then built from source and switched to it.
> >
> > Since there are really only 3 types / configurations of cameras, I
> > only tested the 3 types. I watched the output of 'top' for about a
> > minute for each test. I also waited for the initial startup to settle
> > (time for camera to respond with images) before recording the
> > numbers. I don't have 4.1.1 building yet, so these numbers are for
> > 4.2.2.
> >
> > For the 2MP snapshot camera, after startup, before connecting to the
> > web page, it hovered between 25% and 45% CPU usage.
> > After starting the web page, the numbers hovered between 78.5% and 81.5%.
> >
> > For the 1MP streaming camera (5 frames / sec), it hovered between 23%
> > and 33%.
> > After starting the web page, 33.7% to 45.9%.
> >
> > For the 2MP streaming camera (5 frames / sec), it hovered between 42%
> > and 53.6%.
> > After starting the web page, 63.6% and 70.3%.
> >
> > I'm a little surprised no one had usage numbers between the two
> > versions. Considering I'm using the same configuration files (with
> > updates for the new parameter names in 4.2), I was expecting others
> > would see this problem. It's an issue for me, because I have more
> > cameras I want to add, but at this point with 4.2.2, the CPU is maxed
> > out.
> >
> >
> > --
> > Rob.
> >
> >
> > On 7/18/19 11:12 PM, tosiara wrote:
> >> Could you compare CPU numbers running only one camera? The best to
> >> make 8 separate tests with each camera. This could help to understand
> >> the issue better
> >> Also, which OS are were you using before and now, and which motion
> >> version - binary package or compiled yourself?
> >>
> >> On Thu, Jul 18, 2019 at 9:33 PM rmbusy <[email protected]> wrote:
> >>> I upgraded my system to the latest version of Linux, and at the same
> >>> time, upgraded Motion from 4.1.1 to 4.2.2.
> >>>
> >>> I have 8 RTSP cameras set up, 5 cameras configured for snapshot mode at
> >>> 1 frame per second (all 2MP), and 3 streaming at 5 frames per second (2
> >>> 2MP, 1 1MP). All of this is running on a quad core Rock64 w/ 4GB DRAM,
> >>> at the default CPU frequency (1.3GHz).
> >>>
> >>> With 4.1.1, I was seeing around 150% CPU utilization (via top), and
> >>> when
> >>> connecting to the web page, around 300% CPU utilization. Since the
> >>> Rock64 is a quad core ARM processor, max is 400%.
> >>>
> >>> Now with 4.2.2 and the same camera configuration files (updated with
> >>> new
> >>> option names), I'm seeing CPU utilization of 250%, and when connecting
> >>> to the web page, the numbers are maxed out, and the web page is
> >>> basically non-responsive.
> >>>
> >>> Since I upgraded the underlying OS, I can't rule out that it's
> >>> requiring
> >>> more CPU cycles for Motion to do the same thing, but that seems
> >>> unlikely. Running top doesn't show anything else using CPU cycles
> >>> (other than top).
> >>>
> >>> Can anyone confirm if 4.2.2 is using significantly more CPU cycles than
> >>> 4.1.1? If I can't find a way to reduce the usage, I may have to go
> >>> back
> >>> to 4.1.1.
> >>>
> >>> Any suggestions would be appreciated.
> >>>
> >>>
> >>> --
> >>> Rob.
> >>>
> >>>
> >>>
> >>>
> >>> _______________________________________________
> >>> Motion-user mailing list
> >>> [email protected]
> >>> https://lists.sourceforge.net/lists/listinfo/motion-user
> >>> https://motion-project.github.io/
> >>>
> >>> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
> >>
> >> _______________________________________________
> >> Motion-user mailing list
> >> [email protected]
> >> https://lists.sourceforge.net/lists/listinfo/motion-user
> >> https://motion-project.github.io/
> >>
> >> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
> >
>
>
>
> _______________________________________________
> Motion-user mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/motion-user
> https://motion-project.github.io/
>
> Unsubscribe: https://lists.sourceforge.net/lists/options/motion-user
-------------- next part --------------
An HTML attachment was scrubbed...
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image.png
Type: image/png
Size: 17360 bytes
Desc: not available
------------------------------
------------------------------
Subject: Digest Footer
_______________________________________________
Motion-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/motion-user
------------------------------
End of Motion-user Digest, Vol 157, Issue 23
********************************************