Re: [PD] Size of a table
Ok, then in a few days might be ready. Edit the existing help patch and add this stuff, then add it to the patch tracker, and it should be included. At least, I'd include it in Pd-extended. .hc On Jun 22, 2008, at 12:06 PM, João Pais wrote: who is responsible for this object? these features should go to the help patches João Pais And just in case someone on the list hasn't seen this, http://crca.ucsd.edu/~syadegar/expr.html gives documentation for the expr expr~ fexpr~ objects. Table functions (including size(), sum(), and Sum() ) at the very bottom. Matt Date: Wed, 11 Jun 2008 15:03:56 +0100 From: Andy Farnell [EMAIL PROTECTED] Subject: Re: [PD] Size of a table To: pd-list@iem.at Message-ID: [EMAIL PROTECTED] Content-Type: text/plain; charset=ISO-8859-1 On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks ___ Der fr?he Vogel f?ngt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de -- Use the source ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list --Friedenstr. 58 10249 Berlin Deutschland Tel +49 30 42020091 Mob +49 162 6843570 [EMAIL PROTECTED] skype: jmmmpjmmmp http://www.puredata.org/Members/jmmmp IBM Thinkpad R51, XP, Ubuntu GG Pd-Ext-0.39-2-t5, Pd Van 0.40-t2 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list Access to computers should be unlimited and total. - the hacker ethic -- Friedenstr. 58 10249 Berlin Deutschland Tel +49 30 42020091 Mob +49 162 6843570 [EMAIL PROTECTED] skype: jmmmpjmmmp http://www.puredata.org/Members/jmmmp IBM Thinkpad R51, XP, Ubuntu GG Pd-Ext-0.39-2-t5, Pd Van 0.40-t2 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
who is responsible for this object? these features should go to the help patches João Pais And just in case someone on the list hasn't seen this, http://crca.ucsd.edu/~syadegar/expr.html gives documentation for the expr expr~ fexpr~ objects. Table functions (including size(), sum(), and Sum() ) at the very bottom. Matt Date: Wed, 11 Jun 2008 15:03:56 +0100 From: Andy Farnell [EMAIL PROTECTED] Subject: Re: [PD] Size of a table To: pd-list@iem.at Message-ID: [EMAIL PROTECTED] Content-Type: text/plain; charset=ISO-8859-1 On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks ___ Der fr?he Vogel f?ngt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de -- Use the source ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- Friedenstr. 58 10249 Berlin Deutschland Tel +49 30 42020091 Mob +49 162 6843570 [EMAIL PROTECTED] skype: jmmmpjmmmp http://www.puredata.org/Members/jmmmp IBM Thinkpad R51, XP, Ubuntu GG Pd-Ext-0.39-2-t5, Pd Van 0.40-t2 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
Edit the existing help patch and add this stuff, then add it to the patch tracker, and it should be included. At least, I'd include it in Pd-extended. .hc On Jun 22, 2008, at 12:06 PM, João Pais wrote: who is responsible for this object? these features should go to the help patches João Pais And just in case someone on the list hasn't seen this, http://crca.ucsd.edu/~syadegar/expr.html gives documentation for the expr expr~ fexpr~ objects. Table functions (including size(), sum(), and Sum() ) at the very bottom. Matt Date: Wed, 11 Jun 2008 15:03:56 +0100 From: Andy Farnell [EMAIL PROTECTED] Subject: Re: [PD] Size of a table To: pd-list@iem.at Message-ID: [EMAIL PROTECTED] Content-Type: text/plain; charset=ISO-8859-1 On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks ___ Der fr?he Vogel f?ngt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de -- Use the source ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- Friedenstr. 58 10249 Berlin Deutschland Tel +49 30 42020091 Mob +49 162 6843570 [EMAIL PROTECTED] skype: jmmmpjmmmp http://www.puredata.org/Members/jmmmp IBM Thinkpad R51, XP, Ubuntu GG Pd-Ext-0.39-2-t5, Pd Van 0.40-t2 ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/ listinfo/pd-list Access to computers should be unlimited and total. - the hacker ethic ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On Wed, Jun 11, 2008 at 6:04 AM, marius schebella [EMAIL PROTECTED] wrote: hi, that's cool. did not know that expr can do that! are there more features of expr that are hidden or unknown?? marius. Hi Marius Check it out: http://www.crca.ucsd.edu/~yadegari/expr.html#funcs Cheers Luke At 09:38 11/06/2008, you wrote: On Wed, Jun 11, 2008 at 10:03:28AM +0200, IOhannes m zmoelnig wrote: raul diaz wrote: I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) There is one situation I have encountered where it would be useful to have a built in [arraysize]. In some of the s-abstractions such as [s-samplepiece~] you have to pass in the table name that you'd like the abstraction to use. This means that at some point the user loads some audio data into the named table (for example using [s-loader~]) and they then know the sample table size. When they create the [s-samplepiece~] playback abstraction they must manually enter the array size as one of the arguments to the abstraction, along with the table name. Inefficient. Best, Chris. --- http://mccormick.cx ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On 11/06/2008, at 16.03, Andy Farnell wrote: On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks Agreed. Neat indeed. I've added it to the Tips'n'Tricks page[0]. Hope that's ok. [0] http://puredata.info/docs/tutorials/TipsAndTricks#getting-table- array-size ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
[PD] Size of a table
Hi list! I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? Thanks in advance! -- Raul Diaz Poblete * http://creaciodigital.upf.edu/~i50874/ [EMAIL PROTECTED] Barcelona [Spain] ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
raul diaz wrote: Hi list! I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) anyhow, having said all that, there are several externals that will give you the size of a table. for once there is pix's [arraysize]. and then you could use kludges like [tabdump]-[list length] fgmasdr IOhannes ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On Wed, Jun 11, 2008 at 10:03:28AM +0200, IOhannes m zmoelnig wrote: raul diaz wrote: I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) There is one situation I have encountered where it would be useful to have a built in [arraysize]. In some of the s-abstractions such as [s-samplepiece~] you have to pass in the table name that you'd like the abstraction to use. This means that at some point the user loads some audio data into the named table (for example using [s-loader~]) and they then know the sample table size. When they create the [s-samplepiece~] playback abstraction they must manually enter the array size as one of the arguments to the abstraction, along with the table name. Inefficient. Best, Chris. --- http://mccormick.cx ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print or replace the expr with [expr size($s2)] and connect a message [symbol array1( to the second inlet of this expr object hans r At 09:38 11/06/2008, you wrote: On Wed, Jun 11, 2008 at 10:03:28AM +0200, IOhannes m zmoelnig wrote: raul diaz wrote: I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) There is one situation I have encountered where it would be useful to have a built in [arraysize]. In some of the s-abstractions such as [s-samplepiece~] you have to pass in the table name that you'd like the abstraction to use. This means that at some point the user loads some audio data into the named table (for example using [s-loader~]) and they then know the sample table size. When they create the [s-samplepiece~] playback abstraction they must manually enter the array size as one of the arguments to the abstraction, along with the table name. Inefficient. Best, Chris. --- http://mccormick.cx ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
Hi list! Thanks for your answers! I think arraysize is the best way to obtain table size in my case. I know as IOhannes said that I can use the length output from soundfiler, but I load a lot of samples at the same time in the same soundfiler, so it's difficult to get each size separately. I have an abstraction which plays synchronized with a master tempo a drums loop, and it has as argument its table name. So I think the best way is to get the table size with [arraysize $1] or as Hans suggested [expr size($s2)] for pd-vanilla. Saludos! 2008/6/11 Hans Roels [EMAIL PROTECTED]: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print or replace the expr with [expr size($s2)] and connect a message [symbol array1( to the second inlet of this expr object hans r At 09:38 11/06/2008, you wrote: On Wed, Jun 11, 2008 at 10:03:28AM +0200, IOhannes m zmoelnig wrote: raul diaz wrote: I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) There is one situation I have encountered where it would be useful to have a built in [arraysize]. In some of the s-abstractions such as [s-samplepiece~] you have to pass in the table name that you'd like the abstraction to use. This means that at some point the user loads some audio data into the named table (for example using [s-loader~]) and they then know the sample table size. When they create the [s-samplepiece~] playback abstraction they must manually enter the array size as one of the arguments to the abstraction, along with the table name. Inefficient. Best, Chris. --- http://mccormick.cx ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list -- Raul Diaz Poblete * http://creaciodigital.upf.edu/~i50874/ [EMAIL PROTECTED] Barcelona [Spain] ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print or replace the expr with [expr size($s2)] and connect a message [symbol array1( to the second inlet of this expr object hans r hi, that's cool. did not know that expr can do that! are there more features of expr that are hidden or unknown?? marius. At 09:38 11/06/2008, you wrote: On Wed, Jun 11, 2008 at 10:03:28AM +0200, IOhannes m zmoelnig wrote: raul diaz wrote: I have a dumb question. What's the best way to get the size of a table? Sometimes I load a lot of samples on tables with soundfiler and I would like to take the size of each sample as a variable in order to use it with phasor + tabread4~. Is there any object which gets the size of a table? well i have a dumb answer: why not use the length output of [soundfiler]? i think that in this case the philosophy of Pd his, that there are 2 ways to change the length of a table: do it interactively (e.g. create a [table bla 1024] or do it programmatically (e.g. via [; bla resize 216() in the first case the author of the software is responsible for using (e.g. hardcoding) the right table-size throughout there patch, in the latter case you could just listen to these programmatical changes). tables suddenly changing there size are beyond Pd :-) There is one situation I have encountered where it would be useful to have a built in [arraysize]. In some of the s-abstractions such as [s-samplepiece~] you have to pass in the table name that you'd like the abstraction to use. This means that at some point the user loads some audio data into the named table (for example using [s-loader~]) and they then know the sample table size. When they create the [s-samplepiece~] playback abstraction they must manually enter the array size as one of the arguments to the abstraction, along with the table name. Inefficient. Best, Chris. --- http://mccormick.cx ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
marius schebella wrote: Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print or replace the expr with [expr size($s2)] and connect a message [symbol array1( to the second inlet of this expr object hans r hi, that's cool. did not know that expr can do that! are there more features of expr that are hidden or unknown?? marius. very nice indeed. i remember sven posted once a way to directly access the value of [value] with expr but i can't remember. eni ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de -- Use the source ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On Wed, 2008-06-11 at 13:18 +0200, raul diaz wrote: Hi list! Thanks for your answers! I think arraysize is the best way to obtain table size in my case. I know as IOhannes said that I can use the length output from soundfiler, but I load a lot of samples at the same time in the same soundfiler, so it's difficult to get each size separately. this is certainly not true. pd's execution order is very strict, so it shouldn't cause any trouble at all to load several samples in 0 logical time through the same [soundfiler] while keeping track of all sample lengths. from pd's perspective, everything is processed sequentially, even if for the user it looks like to happen at the same time. so conceptually, there isn't actually no 'at the same time', so there is also no need to wait until all samples are loaded and then ask each array about its size. roman ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman ___ Der frühe Vogel fängt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list
Re: [PD] Size of a table
And just in case someone on the list hasn't seen this, http://crca.ucsd.edu/~syadegar/expr.html gives documentation for the expr expr~ fexpr~ objects. Table functions (including size(), sum(), and Sum() ) at the very bottom. Matt Date: Wed, 11 Jun 2008 15:03:56 +0100 From: Andy Farnell [EMAIL PROTECTED] Subject: Re: [PD] Size of a table To: pd-list@iem.at Message-ID: [EMAIL PROTECTED] Content-Type: text/plain; charset=ISO-8859-1 On Wed, 11 Jun 2008 13:23:28 +0200 Roman Haefeli [EMAIL PROTECTED] wrote: On Wed, 2008-06-11 at 12:09 +0100, Hans Roels wrote: Apart from [soundfiler] I use this trick to get the size of any array (audio or data) in pd vanilla: (array1 = the name of an example array) bang | [expr size(array1)] | print hey, nice trick. thanks for sharing. roman Yeah, nice! Not seen that before, it's very useful. Thanks ___ Der fr?he Vogel f?ngt den Wurm. Hier gelangen Sie zum neuen Yahoo! Mail: http://mail.yahoo.de -- Use the source ___ Pd-list@iem.at mailing list UNSUBSCRIBE and account-management - http://lists.puredata.info/listinfo/pd-list