Csound Csound-dev Csound-tekno Search About

Re: [Csnd] Real Time Performance - Latency

Date2019-08-03 11:56
FromSlobodan Ivanovic
SubjectRe: [Csnd] Real Time Performance - Latency
Thank you very much guys for your answers! I have a couple of question though.

"...Having too much processing when using smaller buffers though can delay
delivery of samples which can cause breakups in audio." (Steven Yi)

- I kind of understand this statement but It is possible to have an example?

"...then you can try to either apply limits to polyphony or create a fixed audio graph."(Steven Yi)

- What is a fixed audio graph? And how can I create it?

"The one part of Csound that might cause an issue in constrained systems is initialization time. Csound may allocate memory
in these situations, which is generally unpredictable and typically avoided when on audio threads."(Steven Yi)

- What does the initialization time depend on?

"Since then computers have got faster and Victor wrote the real-time mode so I do not expect you to have many probls if you avoid the very heavy opcodes" (John ff)

- Which are some of the very heavy opcodes? (to have an idea)

"On a well-tuned linux, it should work very well. On MacOS, with which I have more experience, 32/64 frames buffers give 
you good performance." (Victor Lazzarini)

-  These 32/64 frames buffers refers to hardware buffer of software buffers? How they differ?

"And if your buffers aren't properly tuned, you'll see the xruns pretty quick." (Guillermo Senna)

- What are xruns?
________________________________________________________________________________________________________________

Is there any way to measure the latency you are having with Csound?
Is there any table that gives the different latency time in differents OS/Audio Drivers (with a standard set-up)?

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2019-08-03 16:41
FromGuillermo Senna
SubjectRe: [Csnd] Real Time Performance - Latency
Hi,

Regarding xruns: https://unix.stackexchange.com/a/225473

On 3/8/19 07:56, Slobodan Ivanovic wrote:
> Thank you very much guys for your answers! I have a couple of question though.
>
> "...Having too much processing when using smaller buffers though can delay
> delivery of samples which can cause breakups in audio." (Steven Yi)
>
> - I kind of understand this statement but It is possible to have an example?
>
> "...then you can try to either apply limits to polyphony or create a fixed audio graph."(Steven Yi)
>
> - What is a fixed audio graph? And how can I create it?
>
> "The one part of Csound that might cause an issue in constrained systems is initialization time. Csound may allocate memory
> in these situations, which is generally unpredictable and typically avoided when on audio threads."(Steven Yi)
>
> - What does the initialization time depend on?
>
> "Since then computers have got faster and Victor wrote the real-time mode so I do not expect you to have many probls if you avoid the very heavy opcodes" (John ff)
>
> - Which are some of the very heavy opcodes? (to have an idea)
>
> "On a well-tuned linux, it should work very well. On MacOS, with which I have more experience, 32/64 frames buffers give 
> you good performance." (Victor Lazzarini)
>
> -  These 32/64 frames buffers refers to hardware buffer of software buffers? How they differ?
>
> "And if your buffers aren't properly tuned, you'll see the xruns pretty quick." (Guillermo Senna)
>
> - What are xruns?
> ________________________________________________________________________________________________________________
>
> Is there any way to measure the latency you are having with Csound?
> Is there any table that gives the different latency time in differents OS/Audio Drivers (with a standard set-up)?
>
> Csound mailing list
> Csound@listserv.heanet.ie
> https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
> Send bugs reports to
>         https://github.com/csound/csound/issues
> Discussions of bugs and features can be posted here

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2019-08-03 16:46
FromGuillermo Senna
SubjectRe: [Csnd] Real Time Performance - Latency
Actually I think this is more accurate regarding xruns and what you were
asking about. From
https://jack-devel.jackaudio.narkive.com/b7EAd9js/what-is-an-xrun:

xrun is common name for either buffer underrun of overrun. Underrun
happens on playback, when soundcard wants new data to buffer but
software is unable to fill the buffer fast enough. Overrun happens on
recording, when soundcard puts new data to buffer but software has not
managed to grab the previous values 'out of the way'

On 3/8/19 12:41, Guillermo Senna wrote:
> Hi,
>
> Regarding xruns: https://unix.stackexchange.com/a/225473
>
> On 3/8/19 07:56, Slobodan Ivanovic wrote:
>> Thank you very much guys for your answers! I have a couple of question though.
>>
>> "...Having too much processing when using smaller buffers though can delay
>> delivery of samples which can cause breakups in audio." (Steven Yi)
>>
>> - I kind of understand this statement but It is possible to have an example?
>>
>> "...then you can try to either apply limits to polyphony or create a fixed audio graph."(Steven Yi)
>>
>> - What is a fixed audio graph? And how can I create it?
>>
>> "The one part of Csound that might cause an issue in constrained systems is initialization time. Csound may allocate memory
>> in these situations, which is generally unpredictable and typically avoided when on audio threads."(Steven Yi)
>>
>> - What does the initialization time depend on?
>>
>> "Since then computers have got faster and Victor wrote the real-time mode so I do not expect you to have many probls if you avoid the very heavy opcodes" (John ff)
>>
>> - Which are some of the very heavy opcodes? (to have an idea)
>>
>> "On a well-tuned linux, it should work very well. On MacOS, with which I have more experience, 32/64 frames buffers give 
>> you good performance." (Victor Lazzarini)
>>
>> -  These 32/64 frames buffers refers to hardware buffer of software buffers? How they differ?
>>
>> "And if your buffers aren't properly tuned, you'll see the xruns pretty quick." (Guillermo Senna)
>>
>> - What are xruns?
>> ________________________________________________________________________________________________________________
>>
>> Is there any way to measure the latency you are having with Csound?
>> Is there any table that gives the different latency time in differents OS/Audio Drivers (with a standard set-up)?
>>
>> Csound mailing list
>> Csound@listserv.heanet.ie
>> https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
>> Send bugs reports to
>>         https://github.com/csound/csound/issues
>> Discussions of bugs and features can be posted here

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2019-08-04 21:09
Fromjohn
SubjectRe: [Csnd] Real Time Performance - Latency
On Sat, 3 Aug 2019, Slobodan Ivanovic wrote:

> "Since then computers have got faster and Victor wrote the real-time mode so I do not expect you to have many probls if you avoid the very heavy opcodes" (John ff)
>
> - Which are some of the very heavy opcodes? (to have an idea)
>


I cannot find my measured notes but thins like the prepared piano string, 
platereverbe, any pvs* opcodes with hopsize less than 5 (ie Sliding DFT if 
you do not have the CUDA rexperimemtal code), long convolutions

I am sure there are other but I do not ue them.

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here