# Peformance Tuning when using GPU encode decode

**URL:** <https://community.wowza.com/t/peformance-tuning-when-using-gpu-encode-decode/93792>\
**Category:** Wowza Streaming Engine\
**Tags:** wowza-streaming-server-java-api, transcoder, encoder\
**Created:** [September 6, 2021, 4:00am UTC](https://community.wowza.com/t/peformance-tuning-when-using-gpu-encode-decode/93792 "2021-09-06T04:00:39Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Brian\_Yu](https://avatars.discourse-cdn.com/v4/letter/b/b5a626/32.png) [@Brian\_Yu](https://community.wowza.com/u/Brian_Yu)\
**Post date:** [September 6, 2021, 4:00am UTC](https://community.wowza.com/t/peformance-tuning-when-using-gpu-encode-decode/93792/1 "2021-09-06T04:00:39Z")

</div>

Hi,

I have few question when I using streaming engine !

I am using AWS g4Xlarge ([Now Available – EC2 Instances (G4) with NVIDIA T4 Tensor Core GPUs | AWS News Blog](https://aws.amazon.com/tw/blogs/aws/now-available-ec2-instances-g4-with-nvidia-t4-tensor-core-gpus/)) for my streaming engine server .  
and reference ([Add graphic overlays to a live stream](https://www.wowza.com/docs/how-to-add-graphic-overlays-to-live-streams-with-wowza-transcoder)) this and only add simple scrolling text to my live stream.

here is my environment  
Memory: 16GB  
Processor Cores: 4  
Wowza Streaming Engine Manager Version  
4.8.14+9 (build 20210719152831)  
OS:Linux (amd64)  
Java Version:9.0.4  
Java VM Version:9.0.4+11  
Java Architecture:64

here is my transcoded config  
_Outgoing Stream Name:mp4:${SourceStreamName}\_720p_  
_Video Codec: H.264_  
_Video Bitrate 1300000_  
_Encoding Implementation: NVENC_  
_Profile: Main_  
_Key Frame Interval:Same as source_

11 live stream at the same time need to transecode

this is source:

_Network Throughput Bytes In is 1.5Mbits/s_

this is transcoded stream:

![Screen Shot 2021-09-06 at 12.10.12 PM](https://us1.discourse-cdn.com/flex002/uploads/wowza1/original/1X/744f62ee0e7d3200503cd50f6c411b996a560f79.png)

question:

1. If I have 5 stream and source is stable ,when transcoded 3 is ok, 2 is bad network throughput bytes In  
I don’t know what I miss in configuration?.
2. I can not use nvcuvid or cuda to decode , I got this 2 warning:  
2.1 Publisher.publish: Stream name already in use  
2.2 Video packet list is full  
after warning gpu will stop to encode and decode

---

<div class="post-metadata">

**Author:** ![Brian\_Yu](https://avatars.discourse-cdn.com/v4/letter/b/b5a626/32.png) [@Brian\_Yu](https://community.wowza.com/u/Brian_Yu)\
**Post date:** [September 7, 2021, 2:27pm UTC](https://community.wowza.com/t/peformance-tuning-when-using-gpu-encode-decode/93792/2 "2021-09-07T14:27:55Z")

</div>

So I decide to downgrade wowza streaming service version to 4.18.12

It’s work but seems have some performance problem

why gpu usage only 10%?  
I received this logs: Video behind filter state change

`Video behind filter state change `  
and these event happen often  
`destroy , unpublish`

I have almost 20 x (720p 3.0Mbps) live stream at same time Which AWS instance type is recommended?
