Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-24 Thread Jonatan Midtgaard
It does seem that you are correct :)

The code I wrote at first fails for some reason. I don't know why, but I
can definitely do what I want now. Thanks a lot for the clarification!

- Jonatan

Den ons. 24. okt. 2018 kl. 19.32 skrev Yann Orlarey :

> Hi Jonatan,
>
> I am not sure to understand what the problem is?
>
> import("stdfaust.lib");
> process = control(os.osc(440), choice==0), control(os.osc(660), choice==1)
> :> _;
> choice  = button("choice");
>
>
> In the above code, only one of the two branches will be computed and the
> choice will be done at runtime. The semantics of `control` is
> (approximatively) the following:
>
> control(x,y) = x@D(y) with { D(y) = y==0 : +~_; };
>
> Cheers
>
> Yann
>
>
> Le mer. 24 oct. 2018 à 16:56, Stéphane Letz  a écrit :
>
>> A bit occupied these days, we’ll look at the issue not before next week.
>>
>> Stéphane
>>
>>
>> > Le 24 oct. 2018 à 13:19, Jonatan Midtgaard 
>> a écrit :
>> >
>> > Just bumping this thread in case no one saw it.
>> >
>> > Should it possible to be change the branch at runtime? Because that
>> seems broken at the moment.
>> >
>> > - Jonatan
>> >
>> >> On 17 Oct 2018, at 12.26, Jonatan Midtgaard <
>> jonatan.midtga...@gmail.com> wrote:
>> >>
>> >> Tested and it works!
>> >>
>> >> Follow-up question:
>> >> Is it possible to change the 'branch' that is calculated at runtime?
>> Doing this naively with an hslider or button
>> >>
>> >> var(0) = 5;
>> >> var(1) = 9;
>> >> choice = button("choice");
>> >> process = control(var(0),choice==0), control(var(1),choice==1) :> _;
>> >>
>> >> Still fails when compiled with
>> >> faust -scal -es 1 -lang ocpp
>> >>
>> >> - Jonatan
>> >>
>> >> Den lør. 13. okt. 2018 kl. 09.32 skrev :
>> >> Fixed on GIT master-dev branch (compiler version 2.11.10)
>> >>
>> >> Stéphane
>> >>
>> >>
>> >> > Le 12 oct. 2018 à 11:05, Jonatan Midtgaard <
>> jonatan.midtga...@gmail.com> a écrit :
>> >> >
>> >> > Thanks for the quick response. Looking forward to hearing about the
>> developments.
>> >> >
>> >> > - Jonatan
>> >> >
>> >> > fre. 12. okt. 2018 17.02 skrev Stéphane Letz :
>> >> > >
>> >> > > ASSERT : please report this message, the stack trace, and the
>> failing DSP file to Faust developers (file: mterm.cpp, line: 511, version:
>> 2.11.9, options: ocpp, -scal -ftz 0)
>> >> >
>> >> > The reported message is indeed correct ! This reveal an issue in the
>> compiler, we are working on it.
>> >> >
>> >> > Thanks.
>> >> >
>> >> > Stéphane
>> >>
>> >
>>
>>
>>
>> ___
>> Faudiostream-users mailing list
>> Faudiostream-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/faudiostream-users
>>
>
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-24 Thread Yann Orlarey
Hi Jonatan,

I am not sure to understand what the problem is?

import("stdfaust.lib");
process = control(os.osc(440), choice==0), control(os.osc(660), choice==1)
:> _;
choice  = button("choice");


In the above code, only one of the two branches will be computed and the
choice will be done at runtime. The semantics of `control` is
(approximatively) the following:

control(x,y) = x@D(y) with { D(y) = y==0 : +~_; };

Cheers

Yann


Le mer. 24 oct. 2018 à 16:56, Stéphane Letz  a écrit :

> A bit occupied these days, we’ll look at the issue not before next week.
>
> Stéphane
>
>
> > Le 24 oct. 2018 à 13:19, Jonatan Midtgaard 
> a écrit :
> >
> > Just bumping this thread in case no one saw it.
> >
> > Should it possible to be change the branch at runtime? Because that
> seems broken at the moment.
> >
> > - Jonatan
> >
> >> On 17 Oct 2018, at 12.26, Jonatan Midtgaard <
> jonatan.midtga...@gmail.com> wrote:
> >>
> >> Tested and it works!
> >>
> >> Follow-up question:
> >> Is it possible to change the 'branch' that is calculated at runtime?
> Doing this naively with an hslider or button
> >>
> >> var(0) = 5;
> >> var(1) = 9;
> >> choice = button("choice");
> >> process = control(var(0),choice==0), control(var(1),choice==1) :> _;
> >>
> >> Still fails when compiled with
> >> faust -scal -es 1 -lang ocpp
> >>
> >> - Jonatan
> >>
> >> Den lør. 13. okt. 2018 kl. 09.32 skrev :
> >> Fixed on GIT master-dev branch (compiler version 2.11.10)
> >>
> >> Stéphane
> >>
> >>
> >> > Le 12 oct. 2018 à 11:05, Jonatan Midtgaard <
> jonatan.midtga...@gmail.com> a écrit :
> >> >
> >> > Thanks for the quick response. Looking forward to hearing about the
> developments.
> >> >
> >> > - Jonatan
> >> >
> >> > fre. 12. okt. 2018 17.02 skrev Stéphane Letz :
> >> > >
> >> > > ASSERT : please report this message, the stack trace, and the
> failing DSP file to Faust developers (file: mterm.cpp, line: 511, version:
> 2.11.9, options: ocpp, -scal -ftz 0)
> >> >
> >> > The reported message is indeed correct ! This reveal an issue in the
> compiler, we are working on it.
> >> >
> >> > Thanks.
> >> >
> >> > Stéphane
> >>
> >
>
>
>
> ___
> Faudiostream-users mailing list
> Faudiostream-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/faudiostream-users
>
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-24 Thread Stéphane Letz
A bit occupied these days, we’ll look at the issue not before next week.

Stéphane 


> Le 24 oct. 2018 à 13:19, Jonatan Midtgaard  a 
> écrit :
> 
> Just bumping this thread in case no one saw it.
> 
> Should it possible to be change the branch at runtime? Because that seems 
> broken at the moment.
> 
> - Jonatan
> 
>> On 17 Oct 2018, at 12.26, Jonatan Midtgaard  
>> wrote:
>> 
>> Tested and it works!
>> 
>> Follow-up question:
>> Is it possible to change the 'branch' that is calculated at runtime? Doing 
>> this naively with an hslider or button   
>> 
>> var(0) = 5;
>> var(1) = 9;
>> choice = button("choice");
>> process = control(var(0),choice==0), control(var(1),choice==1) :> _;
>> 
>> Still fails when compiled with 
>> faust -scal -es 1 -lang ocpp
>> 
>> - Jonatan
>> 
>> Den lør. 13. okt. 2018 kl. 09.32 skrev :
>> Fixed on GIT master-dev branch (compiler version 2.11.10)
>> 
>> Stéphane 
>> 
>> 
>> > Le 12 oct. 2018 à 11:05, Jonatan Midtgaard  a 
>> > écrit :
>> > 
>> > Thanks for the quick response. Looking forward to hearing about the 
>> > developments.
>> > 
>> > - Jonatan
>> > 
>> > fre. 12. okt. 2018 17.02 skrev Stéphane Letz :
>> > > 
>> > > ASSERT : please report this message, the stack trace, and the failing 
>> > > DSP file to Faust developers (file: mterm.cpp, line: 511, version: 
>> > > 2.11.9, options: ocpp, -scal -ftz 0)
>> > 
>> > The reported message is indeed correct ! This reveal an issue in the 
>> > compiler, we are working on it.
>> > 
>> > Thanks.
>> > 
>> > Stéphane
>> 
> 



___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-24 Thread Jonatan Midtgaard
Just bumping this thread in case no one saw it.

Should it possible to be change the branch at runtime? Because that seems 
broken at the moment.

- Jonatan

> On 17 Oct 2018, at 12.26, Jonatan Midtgaard  
> wrote:
> 
> Tested and it works!
> 
> Follow-up question:
> Is it possible to change the 'branch' that is calculated at runtime? Doing 
> this naively with an hslider or button   
> 
> var(0) = 5;
> var(1) = 9;
> choice = button("choice");
> process = control(var(0),choice==0), control(var(1),choice==1) :> _;
> 
> Still fails when compiled with 
> faust -scal -es 1 -lang ocpp
> 
> - Jonatan
> 
> Den lør. 13. okt. 2018 kl. 09.32 skrev mailto:l...@grame.fr>>:
> Fixed on GIT master-dev branch (compiler version 2.11.10)
> 
> Stéphane 
> 
> 
> > Le 12 oct. 2018 à 11:05, Jonatan Midtgaard  > > a écrit :
> > 
> > Thanks for the quick response. Looking forward to hearing about the 
> > developments.
> > 
> > - Jonatan
> > 
> > fre. 12. okt. 2018 17.02 skrev Stéphane Letz  > >:
> > > 
> > > ASSERT : please report this message, the stack trace, and the failing DSP 
> > > file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9, 
> > > options: ocpp, -scal -ftz 0)
> > 
> > The reported message is indeed correct ! This reveal an issue in the 
> > compiler, we are working on it.
> > 
> > Thanks.
> > 
> > Stéphane
> 

___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-16 Thread Jonatan Midtgaard
Tested and it works!

Follow-up question:
Is it possible to change the 'branch' that is calculated at runtime? Doing
this naively with an hslider or button

var(0) = 5;
var(1) = 9;
choice = button("choice");
process = control(var(0),choice==0), control(var(1),choice==1) :> _;

Still fails when compiled with
faust -scal -es 1 -lang ocpp

- Jonatan

Den lør. 13. okt. 2018 kl. 09.32 skrev :

> Fixed on GIT master-dev branch (compiler version 2.11.10)
>
> Stéphane
>
>
> > Le 12 oct. 2018 à 11:05, Jonatan Midtgaard 
> a écrit :
> >
> > Thanks for the quick response. Looking forward to hearing about the
> developments.
> >
> > - Jonatan
> >
> > fre. 12. okt. 2018 17.02 skrev Stéphane Letz :
> > >
> > > ASSERT : please report this message, the stack trace, and the failing
> DSP file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9,
> options: ocpp, -scal -ftz 0)
> >
> > The reported message is indeed correct ! This reveal an issue in the
> compiler, we are working on it.
> >
> > Thanks.
> >
> > Stéphane
>
>
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-13 Thread letz
Fixed on GIT master-dev branch (compiler version 2.11.10)

Stéphane 


> Le 12 oct. 2018 à 11:05, Jonatan Midtgaard  a 
> écrit :
> 
> Thanks for the quick response. Looking forward to hearing about the 
> developments.
> 
> - Jonatan
> 
> fre. 12. okt. 2018 17.02 skrev Stéphane Letz :
> > 
> > ASSERT : please report this message, the stack trace, and the failing DSP 
> > file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9, 
> > options: ocpp, -scal -ftz 0)
> 
> The reported message is indeed correct ! This reveal an issue in the 
> compiler, we are working on it.
> 
> Thanks.
> 
> Stéphane



___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-12 Thread Jonatan Midtgaard
Thanks for the quick response. Looking forward to hearing about the
developments.

- Jonatan

fre. 12. okt. 2018 17.02 skrev Stéphane Letz :

> >
> > ASSERT : please report this message, the stack trace, and the failing
> DSP file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9,
> options: ocpp, -scal -ftz 0)
>
> The reported message is indeed correct ! This reveal an issue in the
> compiler, we are working on it.
>
> Thanks.
>
> Stéphane
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-12 Thread Stéphane Letz
> 
> ASSERT : please report this message, the stack trace, and the failing DSP 
> file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9, 
> options: ocpp, -scal -ftz 0)

The reported message is indeed correct ! This reveal an issue in the compiler, 
we are working on it.

Thanks.

Stéphane

___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-12 Thread Jonatan Midtgaard
A short code is attached. Compiling with

faust -scal -es 1 -lang ocpp controltest.dsp -o "controltest.faust.hpp"

this gives the error message

A[0] == SigEnable[5,0]
ASSERT : please report this message, the stack trace, and the failing DSP
file to Faust developers (file: mterm.cpp, line: 511, version: 2.11.9,
options: ocpp, -scal -ftz 0)

followed by a stack trace. Changing the -es flag to 0 compiles fine.

- Jonatan


Den fre. 12. okt. 2018 kl. 08.49 skrev Stéphane Letz :

> Can you send the problematic code?
>
> Stéphane
>
> > Le 12 oct. 2018 à 08:47, Jonatan Midtgaard 
> a écrit :
> >
> > I have updated to 2.11.9. I am still getting the same errors, and also
> the -lang ocpp option seems to be causing trouble. Is there an example of
> these primitives so I can check if I am doing things right?
> >
> > - Jonatan
> >
> > tor. 11. okt. 2018 20.28 skrev Stéphane Letz :
> > The control/enable are « experimental » primitives that are still only
> available using the old C++ backend in scalar mode (so doing something like
> faust -lang ocpp foo.dsp, or explicitly giving the -lang ocpp argument to
> faust2xx script, like for instance faust2caqt  -lang ocpp foo.dsp and so
> on…)
> >
> > I’ve just pushed on master-dev some improvements in error message
> reporting when using control/enable incorrectly:
> https://github.com/grame-cncm/faust/commit/d0c5bae907380f2be8c2ff7dc90e5c5a0006892a
> >
> > And we’ll have to implement them in -vec mode, then for all FIR based
> backends.
> >
> > Stéphane
> >
> > > Le 11 oct. 2018 à 12:52, Jonatan Midtgaard <
> jonatan.midtga...@gmail.com> a écrit :
> > >
> > > What is the state of 'true' if statements in Faust at the moment? My
> current understanding was that if i have a series of block diagrams
> > >
> > > f(0) = a;
> > > f(1) = b;
> > > ...
> > >
> > > and I want to be able to choose which block-diagram to execute without
> the others being executed in the background, it could be done with the
> control primitive, e.g.
> > >
> > > in = hslider("Choice",0,0,N,1) : int;
> > > process = par( i, N, control(f(i),in==i) ) :> _;
> > >
> > > I also saw in an old thread that this requires the -es 1 compiler
> flag. However, this results in a compiler error, referring to SigEnable.
> > >
> > > How correct is my understanding, and should this work?
> > >
> > > - Jonatan
> > >
> > > PS: compiler version is 2.10.0
> > > ___
> > > Faudiostream-users mailing list
> > > Faudiostream-users@lists.sourceforge.net
> > > https://lists.sourceforge.net/lists/listinfo/faudiostream-users
> >
>
>


controltest.dsp
Description: Binary data
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-12 Thread Stéphane Letz
Can you send the problematic code?

Stéphane

> Le 12 oct. 2018 à 08:47, Jonatan Midtgaard  a 
> écrit :
> 
> I have updated to 2.11.9. I am still getting the same errors, and also the 
> -lang ocpp option seems to be causing trouble. Is there an example of these 
> primitives so I can check if I am doing things right?
> 
> - Jonatan
> 
> tor. 11. okt. 2018 20.28 skrev Stéphane Letz :
> The control/enable are « experimental » primitives that are still only 
> available using the old C++ backend in scalar mode (so doing something like 
> faust -lang ocpp foo.dsp, or explicitly giving the -lang ocpp argument to 
> faust2xx script, like for instance faust2caqt  -lang ocpp foo.dsp and so on…)
> 
> I’ve just pushed on master-dev some improvements in error message reporting 
> when using control/enable incorrectly: 
> https://github.com/grame-cncm/faust/commit/d0c5bae907380f2be8c2ff7dc90e5c5a0006892a
> 
> And we’ll have to implement them in -vec mode, then for all FIR based 
> backends.
> 
> Stéphane 
> 
> > Le 11 oct. 2018 à 12:52, Jonatan Midtgaard  a 
> > écrit :
> > 
> > What is the state of 'true' if statements in Faust at the moment? My 
> > current understanding was that if i have a series of block diagrams
> > 
> > f(0) = a;
> > f(1) = b;
> > ...
> > 
> > and I want to be able to choose which block-diagram to execute without the 
> > others being executed in the background, it could be done with the control 
> > primitive, e.g.
> > 
> > in = hslider("Choice",0,0,N,1) : int;
> > process = par( i, N, control(f(i),in==i) ) :> _;
> > 
> > I also saw in an old thread that this requires the -es 1 compiler flag. 
> > However, this results in a compiler error, referring to SigEnable. 
> > 
> > How correct is my understanding, and should this work?
> > 
> > - Jonatan
> > 
> > PS: compiler version is 2.10.0
> > ___
> > Faudiostream-users mailing list
> > Faudiostream-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/faudiostream-users
> 



___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-12 Thread Jonatan Midtgaard
I have updated to 2.11.9. I am still getting the same errors, and also the
-lang ocpp option seems to be causing trouble. Is there an example of these
primitives so I can check if I am doing things right?

- Jonatan

tor. 11. okt. 2018 20.28 skrev Stéphane Letz :

> The control/enable are « experimental » primitives that are still only
> available using the old C++ backend in scalar mode (so doing something like
> faust -lang ocpp foo.dsp, or explicitly giving the -lang ocpp argument to
> faust2xx script, like for instance faust2caqt  -lang ocpp foo.dsp and so
> on…)
>
> I’ve just pushed on master-dev some improvements in error message
> reporting when using control/enable incorrectly:
> https://github.com/grame-cncm/faust/commit/d0c5bae907380f2be8c2ff7dc90e5c5a0006892a
>
> And we’ll have to implement them in -vec mode, then for all FIR based
> backends.
>
> Stéphane
>
> > Le 11 oct. 2018 à 12:52, Jonatan Midtgaard 
> a écrit :
> >
> > What is the state of 'true' if statements in Faust at the moment? My
> current understanding was that if i have a series of block diagrams
> >
> > f(0) = a;
> > f(1) = b;
> > ...
> >
> > and I want to be able to choose which block-diagram to execute without
> the others being executed in the background, it could be done with the
> control primitive, e.g.
> >
> > in = hslider("Choice",0,0,N,1) : int;
> > process = par( i, N, control(f(i),in==i) ) :> _;
> >
> > I also saw in an old thread that this requires the -es 1 compiler flag.
> However, this results in a compiler error, referring to SigEnable.
> >
> > How correct is my understanding, and should this work?
> >
> > - Jonatan
> >
> > PS: compiler version is 2.10.0
> > ___
> > Faudiostream-users mailing list
> > Faudiostream-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/faudiostream-users
>
>
___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users


Re: [Faudiostream-users] Status of control/enable primitives and the -es compiler option

2018-10-11 Thread Stéphane Letz
The control/enable are « experimental » primitives that are still only 
available using the old C++ backend in scalar mode (so doing something like 
faust -lang ocpp foo.dsp, or explicitly giving the -lang ocpp argument to 
faust2xx script, like for instance faust2caqt  -lang ocpp foo.dsp and so on…)

I’ve just pushed on master-dev some improvements in error message reporting 
when using control/enable incorrectly: 
https://github.com/grame-cncm/faust/commit/d0c5bae907380f2be8c2ff7dc90e5c5a0006892a

And we’ll have to implement them in -vec mode, then for all FIR based backends.

Stéphane 

> Le 11 oct. 2018 à 12:52, Jonatan Midtgaard  a 
> écrit :
> 
> What is the state of 'true' if statements in Faust at the moment? My current 
> understanding was that if i have a series of block diagrams
> 
> f(0) = a;
> f(1) = b;
> ...
> 
> and I want to be able to choose which block-diagram to execute without the 
> others being executed in the background, it could be done with the control 
> primitive, e.g.
> 
> in = hslider("Choice",0,0,N,1) : int;
> process = par( i, N, control(f(i),in==i) ) :> _;
> 
> I also saw in an old thread that this requires the -es 1 compiler flag. 
> However, this results in a compiler error, referring to SigEnable. 
> 
> How correct is my understanding, and should this work?
> 
> - Jonatan
> 
> PS: compiler version is 2.10.0
> ___
> Faudiostream-users mailing list
> Faudiostream-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/faudiostream-users



___
Faudiostream-users mailing list
Faudiostream-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/faudiostream-users