[Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

[Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

jdm771
Hi,

I would like to scatter sound events uniformly in time over a span of
several hours.

I am using a Mac (Csound v6.11) and using the CsoundQt front end (v0.9.5.1).

The below code will work fine on the first run. However, when I stop it
fully and then try to run it a second time, it will hang up the computer. I
then have to force-quit CsoundQt.

If I make the TOTAL_DURATION macro something like 120 seconds, it will work
every time, without hanging up the computer.

I have tried a variety of things such as delaying the start time to give it
more time to fill up the event queue, using an e statement with a
sufficiently long duration, making the i10 score statement duration longer
to give it more time to fill the event queue, and tweaking the f0 duration.

I have realized that if I wait about 1-2 minutes before I run the .csd file
again, it does not hang up the computer. But waiting like that is not ideal.

I am wondering if I need to clear the "event queue" somehow before I run the
.csd file again? Will you please assist me on this question?

Thank you!


<CsoundSynthesizer>
<CsOptions>
</CsOptions>
<CsInstruments>

sr = 48000
ksmps = 32
0dbfs  = 1
nchnls = 1

#define TOTAL_DURATION #18000# ; Total duration in seconds.

instr 10
        itimes = $TOTAL_DURATION/3 ; Number of events to produce (i.e., 6000).
        icnt = 0
        loop:
                istart unirand $TOTAL_DURATION ; Distribute sound events uniformly within
0 to 18000 seconds.
                event_i "i", 100, istart, 3
        loop_lt icnt, 1, itimes, loop ; End of the i-time loop.
endin

instr 100
        asig oscil 0.1, random(400, 800)
        kamp linseg 0, 0.2, 1, p3-0.4, 1, 0.2, 0
        asig *= kamp
        out asig
endin

</CsInstruments>
<CsScore>

f0 18000

i10 0 10

</CsScore>
</CsoundSynthesizer>



--
Sent from: http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html

Csound mailing list
[hidden email]
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
Reply | Threaded
Open this post in threaded view
|

Re: [Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

Steven Yi
I tried it here on commandline and found I could use ctrl-c to stop
Csound. That i-rate loop does take a while to run though before sound
commences.  I don't see the typical csound end of performance
information though after ctrl-c.  Seems like it might be an issue with
CsoundQT?  Have you tried run in terminal?
On Mon, Sep 3, 2018 at 3:57 PM jdm771 <[hidden email]> wrote:

>
> Hi,
>
> I would like to scatter sound events uniformly in time over a span of
> several hours.
>
> I am using a Mac (Csound v6.11) and using the CsoundQt front end (v0.9.5.1).
>
> The below code will work fine on the first run. However, when I stop it
> fully and then try to run it a second time, it will hang up the computer. I
> then have to force-quit CsoundQt.
>
> If I make the TOTAL_DURATION macro something like 120 seconds, it will work
> every time, without hanging up the computer.
>
> I have tried a variety of things such as delaying the start time to give it
> more time to fill up the event queue, using an e statement with a
> sufficiently long duration, making the i10 score statement duration longer
> to give it more time to fill the event queue, and tweaking the f0 duration.
>
> I have realized that if I wait about 1-2 minutes before I run the .csd file
> again, it does not hang up the computer. But waiting like that is not ideal.
>
> I am wondering if I need to clear the "event queue" somehow before I run the
> .csd file again? Will you please assist me on this question?
>
> Thank you!
>
>
> <CsoundSynthesizer>
> <CsOptions>
> </CsOptions>
> <CsInstruments>
>
> sr = 48000
> ksmps = 32
> 0dbfs  = 1
> nchnls = 1
>
> #define TOTAL_DURATION #18000# ; Total duration in seconds.
>
> instr 10
>         itimes = $TOTAL_DURATION/3 ; Number of events to produce (i.e., 6000).
>         icnt = 0
>         loop:
>                 istart unirand $TOTAL_DURATION ; Distribute sound events uniformly within
> 0 to 18000 seconds.
>                 event_i "i", 100, istart, 3
>         loop_lt icnt, 1, itimes, loop ; End of the i-time loop.
> endin
>
> instr 100
>         asig oscil 0.1, random(400, 800)
>         kamp linseg 0, 0.2, 1, p3-0.4, 1, 0.2, 0
>         asig *= kamp
>         out asig
> endin
>
> </CsInstruments>
> <CsScore>
>
> f0 18000
>
> i10 0 10
>
> </CsScore>
> </CsoundSynthesizer>
>
>
>
> --
> Sent from: http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html
>
> Csound mailing list
> [hidden email]
> 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
[hidden email]
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
Reply | Threaded
Open this post in threaded view
|

Re: [Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

Tarmo Johannes-3
Hi,

I have no problem stopping and restarting the csd in CsoundQt as many times
needed on Linux (both self built from git). I hope to remind and try on MacOS
- there have been alsom similar reports on other cases that starting csd
second time hangs CsoundQt on some cases.

greetings,
tarmo

On kolmapäev, 5. september 2018 16:38.50 EEST you wrote:

> I tried it here on commandline and found I could use ctrl-c to stop
> Csound. That i-rate loop does take a while to run though before sound
> commences.  I don't see the typical csound end of performance
> information though after ctrl-c.  Seems like it might be an issue with
> CsoundQT?  Have you tried run in terminal?
>
> On Mon, Sep 3, 2018 at 3:57 PM jdm771 <[hidden email]> wrote:
> > Hi,
> >
> > I would like to scatter sound events uniformly in time over a span of
> > several hours.
> >
> > I am using a Mac (Csound v6.11) and using the CsoundQt front end
> > (v0.9.5.1).
> >
> > The below code will work fine on the first run. However, when I stop it
> > fully and then try to run it a second time, it will hang up the computer.
> > I
> > then have to force-quit CsoundQt.
> >
> > If I make the TOTAL_DURATION macro something like 120 seconds, it will
> > work
> > every time, without hanging up the computer.
> >
> > I have tried a variety of things such as delaying the start time to give
> > it
> > more time to fill up the event queue, using an e statement with a
> > sufficiently long duration, making the i10 score statement duration longer
> > to give it more time to fill the event queue, and tweaking the f0
> > duration.
> >
> > I have realized that if I wait about 1-2 minutes before I run the .csd
> > file
> > again, it does not hang up the computer. But waiting like that is not
> > ideal.
> >
> > I am wondering if I need to clear the "event queue" somehow before I run
> > the .csd file again? Will you please assist me on this question?
> >
> > Thank you!
> >
> >
> > <CsoundSynthesizer>
> > <CsOptions>
> > </CsOptions>
> > <CsInstruments>
> >
> > sr = 48000
> > ksmps = 32
> > 0dbfs  = 1
> > nchnls = 1
> >
> > #define TOTAL_DURATION #18000# ; Total duration in seconds.
> >
> > instr 10
> >
> >         itimes = $TOTAL_DURATION/3 ; Number of events to produce (i.e.,
> >         6000).
> >         icnt = 0
> >        
> >         loop:
> >                 istart unirand $TOTAL_DURATION ; Distribute sound events
> >                 uniformly within
> >
> > 0 to 18000 seconds.
> >
> >                 event_i "i", 100, istart, 3
> >        
> >         loop_lt icnt, 1, itimes, loop ; End of the i-time loop.
> >
> > endin
> >
> > instr 100
> >
> >         asig oscil 0.1, random(400, 800)
> >         kamp linseg 0, 0.2, 1, p3-0.4, 1, 0.2, 0
> >         asig *= kamp
> >         out asig
> >
> > endin
> >
> > </CsInstruments>
> > <CsScore>
> >
> > f0 18000
> >
> > i10 0 10
> >
> > </CsScore>
> > </CsoundSynthesizer>
> >
> >
> >
> > --
> > Sent from:
> > http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html
> >
> > Csound mailing list
> > [hidden email]
> > 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
> [hidden email]
> 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
[hidden email]
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
Reply | Threaded
Open this post in threaded view
|

Re: [Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

jdm771
In reply to this post by Steven Yi
Thank you for the tip. It seems to be working in the terminal.



--
Sent from: http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html

Csound mailing list
[hidden email]
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
Reply | Threaded
Open this post in threaded view
|

Re: [Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

jdm771
In reply to this post by Tarmo Johannes-3
Thank you for your reply. I tried running the example .csd file in the
terminal and it worked. However, I then ran the example .csd file and
several more similar .csd files in CsoundQT and had it hang only once. This
is strange, because over the past several days it had been behaving as I
described above (i.e., hanging on the second run). I am not sure what has
changed.



--
Sent from: http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html

Csound mailing list
[hidden email]
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
Reply | Threaded
Open this post in threaded view
|

Re: [Csnd] Distributing Sounds Uniformly Over Several Hours and Hanging Computer

joachim heintz
i'd say, if you don't need csoundqt's widgets, for a job like yours
running csound via terminal is always the best choice.  as you may know,
you can also do it from inside csoundqt via the "Run in Term" button.

        joachim



On 07/09/18 17:26, jdm771 wrote:

> Thank you for your reply. I tried running the example .csd file in the
> terminal and it worked. However, I then ran the example .csd file and
> several more similar .csd files in CsoundQT and had it hang only once. This
> is strange, because over the past several days it had been behaving as I
> described above (i.e., hanging on the second run). I am not sure what has
> changed.
>
>
>
> --
> Sent from: http://csound.1045644.n5.nabble.com/Csound-General-f1093014.html
>
> Csound mailing list
> [hidden email]
> 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
[hidden email]
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