Inconsistant Performance for BlueIris UI3

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
I have noticed something else thou, I am getting very high RAM usage, like right this second its using 12Gb out of the 16Gb. Thats what the BI service itself is using.

Would adding more RAM (say another 16Gb chip) help with performance in any meaningful way?
It could, though I don't know why BI is using that much RAM unless it is leaking memory. My BI load is not that much smaller than yours and it is only using 5 GB.
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
Hi All. I wanted to also report strange behavious in UI3 recently. I have been using UI3 b30 beta for while and just recently switched to the official ui3. (i.e. I didn't realize it wasn't in beta anymore until I went to see if there was an update to the beta and realized it was in production now haha.) In any case, I have been experiencing the "your network connection is not fast enought o handle this stream in realtime. consider changing the streaming quality." I haven't made any changes to my setup in over a month (other than installing updates to BI), and this messages started showing up a week ago or so.

I tested my network connection, and get the full 1Gbps speeds on file transfers, so the network side is fine.

My setup consists of:

i7 6700k (cpu consistently around 30% with GPU around 45-50% utilized)
8GB Memory
11 cameras 2 - 4MP direct to disk (dahua and hikvision)
1 1Gbps network for cameras on vlan (no internet access)
1 Gbps network on main network for RDP / UI3 access
I am usuing stunnel/https setup

I get the same error on both my computers, one on the LAN and one on a Wifi network. I get the message no matter what streaming quality I am using. (0, 1, or 2)

My FPS in UI3 jump between 3 - 6 on the live view screen (which I think is normal, but I still get the message), and on each camera around 16-17. (They are setup to stream at 20fps)
 
Last edited:

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
@kbonnel have you tried bypassing stunnel to see if that is affecting it?

In theory the network speed warning could come up if Blue Iris is falling behind in its stream encoding, but in practice I have not witnessed this ever happen (BI seems to just drop frames if it needs to).

If you have any antivirus/security software running, try disabling it temporarily. This applies both to the Blue Iris server and whatever computer you are running UI3 on.
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
@kbonnel have you tried bypassing stunnel to see if that is affecting it?

In theory the network speed warning could come up if Blue Iris is falling behind in its stream encoding, but in practice I have not witnessed this ever happen (BI seems to just drop frames if it needs to).

If you have any antivirus/security software running, try disabling it temporarily. This applies both to the Blue Iris server and whatever computer you are running UI3 on.
I did try with stunnel off / on, and no matter the configuration I keep getting this error. It is very odd, as I never had this before in the many months I have been using UI2 and UI3 in beta until recently. In BI itself, each camera is at a steady 20fps 100% of the time. (well betwen 19.92 - 20.12 ish)

I feel there have been a few changes recently with Windows (patches, anniversary updates, etc.) that something weird happened.
 

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
I'm not on the latest windows version yet myself. Still on 1709 (type winver at the start menu). If you're on the newer one, that could be contributing...
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
Hmm, I am also on 1709, but I thought it recently updated to the newer 1803 version. But I guess not yet.

UPDATE: my main system is now on 1803, while my other systems are still on 1709.

I am not seeing the issue currently on my laptop (wifi) with 1709 on it, but my main system with 1803 is showing the issue.

Both using Chrome.
 
Last edited:

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
Continued UPDATE: I updated my laptop, which was working fine last on 1709, to 1803, and it still continued to function normally on both WiFi and an Ethernet connection.

So far it seems that the issue is on my desktop system. It is an AMD R7 1700 system with an intel CT gig adapter and an Nvidia 1070. I tried the built in Realtek gig adapter, but got the same issue, so I don't believe it is network related at this point. I am thinking something to do with Windows 10 1803 and AMD CPU combination maybe?
 

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
Hmm... hard to say. Ryzen7 1700 is more than fast enough to handle UI3. If the CPU is the bottleneck, then what happens is UI3 receives frames faster than it can decode them. The size of the frame buffer continues to grow, and if you get to 3 or more seconds worth of un-decoded frames, UI3 shows the message "Your CPU is not fast enough".

But that isn't the error message you reported getting. UI3 also calculates network delay based on the difference between frame timestamps and the real time clock. If the network delay rises to 2+ seconds, UI3 shows the "Your network connection is not fast enough" message. The trick is, it isn't 100% certain to be network problems causing the frame timestamps to increment slower than real time. It could be Blue Iris being starved for some resource.

If you open the "Stats for nerds" panel and watch the graphs, it could hint at the problem.
 
Last edited:

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
Hmm... hard to say. Ryzen7 1700 is more than fast enough to handle UI3. If the CPU is the bottleneck, then what happens is UI3 receives frames faster than it can decode them. The size of the frame buffer continues to grow, and if you get to 3 or more seconds worth of un-decoded frames, UI3 shows the message "Your CPU is not fast enough".

But that isn't the error message you reported getting. UI3 also calculates network delay based on the difference between frame timestamps and the real time clock. If the network delay rises to 2+ seconds, UI3 shows the "Your network connection is not fast enough" message.
AHHH, your last line just made me realize the clock on my desktop is running a lot faster! I actually reset it yesterday, and this morning it is off again. When I look at the clock, the seconds are much faster than it should be. WIll go down this investigation route.
 

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
AHHH, your last line just made me realize the clock on my desktop is running a lot faster! I actually reset it yesterday, and this morning it is off again. When I look at the clock, the seconds are much faster than it should be. WIll go down this investigation route.
Wow. Usually PC clocks are close enough that it takes weeks to get multiple seconds off from real time. I wouldn't be surprised if your clock is messing with all kinds of video playback, not just in UI3.
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
It is definitely weird, and I suspect it has something to do with sleep/wakes. I just rebooted my system, and the clock is running correctly (at least initially) and UI3 is not reporting any issues and is acting normally. I will keep an eye on it for a little bit and see if something changes. If nothing, I will do a sleep/wake and see what happens.
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
UPDATE: After a sleep/wake action, the system clock goes faster, and UI3 reports the issue.

Now I have to figure out what is up with my system.
 

kbonnel

Young grasshopper
Joined
Jun 13, 2016
Messages
53
Reaction score
11
It would seem that there is a known bug with Windows 10 and AMD based systems. I found a new bios update for my system (as of March) that appears to have fixed my problem. I was on a version of the bios release in January 2018 that was supposed to have also fixed the issue, but I guess it didn't. So far everything seems good after a couple of sleep/wake activities.
 

eangulus

Getting the hang of it
Joined
May 19, 2015
Messages
104
Reaction score
6
OK with my issue, there does seem to be a runaway RAM problem.

I can sit here and watch it rise, fill the ram then fall again. Just logging in via RDP I saw it first start at 3Gb RAM for the BI process and watched it rise to 12Gb within about 30-60sec.
 

eangulus

Getting the hang of it
Joined
May 19, 2015
Messages
104
Reaction score
6
Wow. Usually PC clocks are close enough that it takes weeks to get multiple seconds off from real time. I wouldn't be surprised if your clock is messing with all kinds of video playback, not just in UI3.
PM me remote access details and I'll have a look around.
Could find the PM option so started a Conversation....
 

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
Problem solved.

There were two problems actually, neither of them were the Intel graphics driver. That was patched appropriately already.

1) Blue Iris had absurdly high memory usage relative to its camera load. Like, 1200 MP/s load with 22-24 GB commit size as measured by Task Manager. I stumbled into the solution to this one. Believe it or not it was the Camera Properties > Video > Max Rate setting. Yeah. The cameras were mostly 12 FPS, with two at 20 FPS. But the Max Rate setting was in the 40-60 FPS range on all these cameras. Just on a whim I started setting those to appropriate levels and each one resulted in lower and lower memory usage. When all Max Rate settings were set to appropriate values, the commit size was down to 10 GB which is actually very appropriate for a 1200 MP/s load.

2) CPU usage was still too high when remotely viewing camera groups. This turned out to be Blue Iris Options > Other > Scaling at fault. It was set to Bicubic, which is the slowest option. Viewing "All cameras" remotely resulted in 100% server load. After setting the scaling option to Fast, CPU usage dropped to 37%.

Now I'm off to update the wiki page on optimizing Blue Iris performance.
 

eangulus

Getting the hang of it
Joined
May 19, 2015
Messages
104
Reaction score
6
Problem solved.

There were two problems actually, neither of them were the Intel graphics driver. That was patched appropriately already.

1) Blue Iris had absurdly high memory usage relative to its camera load. Like, 1200 MP/s load with 22-24 GB commit size as measured by Task Manager. I stumbled into the solution to this one. Believe it or not it was the Camera Properties > Video > Max Rate setting. Yeah. The cameras were mostly 12 FPS, with two at 20 FPS. But the Max Rate setting was in the 40-60 FPS range on all these cameras. Just on a whim I started setting those to appropriate levels and each one resulted in lower and lower memory usage. When all Max Rate settings were set to appropriate values, the commit size was down to 10 GB which is actually very appropriate for a 1200 MP/s load.

2) CPU usage was still too high when remotely viewing camera groups. This turned out to be Blue Iris Options > Other > Scaling at fault. It was set to Bicubic, which is the slowest option. Viewing "All cameras" remotely resulted in 100% server load. After setting the scaling option to Fast, CPU usage dropped to 37%.

Now I'm off to update the wiki page on optimizing Blue Iris performance.
Thanks again for the help. Can't believe that after many years of using BI I am still learning new things about optimising. THen again I have never done a system with 26 cameras before either, usually never cracking 4-8 cameras.

Just for reference and for anyone else reading this, it also fixed my Frame issue of getting really low FPS on all cam view vs single cam. I am now getting 10fps on all cams and full rame on single cams.
 

bp2008

Staff member
Joined
Mar 10, 2014
Messages
12,672
Reaction score
14,015
Location
USA
Can't believe that after many years of using BI I am still learning new things about optimising.
You and me both. I was shocked at the actual causes of those problems. Optimizing complex systems can be such a delicate task sometimes.
 
Top