[PD] your favorite key:value data structure?

Alexandre Torres Porres porres at gmail.com
Tue Jul 18 20:42:54 CEST 2017


As long as we're at it, what are the difference between [text] and
[cyclone/coll] and where do they do the same thing?

Also, it seems [coll] is deprecated in Max, they have a new object named
[dict], which might be the "python like dictionary" kind of thing, and this
is what Max suggests using instead of coll.

So, I was wondering if there would be any great advantage of cloning [dict]
into cyclone, or if you could do the same things with [text] anyway.

cheers

2017-07-18 15:33 GMT-03:00 Jonathan Wilkes via Pd-list <pd-list at lists.iem.at
>:

> > Hello Jonathan,
>
> > Thanks for your reply.
> > I'm not quite sure what you mean.
>
> > What pd-vanilla object do you use to implement "Variable number of keys
> of arbitrarily typed values"
> [text], [coll], etc.
>
> > or "set number of keys with set value types"?
> data structures
>
> The benefit of the latter is that you know the number of "slots" ahead of
> time so you can populate
> the data without needing to allocate memory.
>
> > I should add that I'm interested ultimately in a data structure that I
> can populate from text files, read by PD.
>
> In that case I don't think the benefit I mentioned wrt data structures
> matters because
> the I/O speed will be your limiting factor.
>
> My suggestion would be to start with the more expressive vanilla object--
> [text]-- and see
> if it fulfills your needs. Keep in mind though that it is at core not a
> key/value store but instead
> a 2-dimensional array of atoms. E.g., you can decide that the first item
> in each line is your
> key, but the text class interface does nothing to prevent you from adding
> more lines that
> duplicate that same key.
>
> -Jonathan
>
> > -ali
>
>
>
> On Tue, Jul 18, 2017 at 1:16 PM, Jonathan Wilkes <jancsika at yahoo.com>
> wrote:
>
> Variable number of keys of arbitrarily typed values, or
> set number of keys with set value types?
>
> -Jonathan
>
>
> ------------------------------
> *From:* Ali Momeni <batchku at gmail.com>
> *To:* Pd-List <pd-list at lists.iem.at>
> *Sent:* Tuesday, July 18, 2017 1:09 PM
> *Subject:* [PD] your favorite key:value data structure?
>
> Hello all,
>
> I'm looking for something analogous to the Max "coll" object, or a python
> dictionary, or anything with key value pairs.
>
> I'm aware of the 'cyclone' and its 'coll' object.
>
> i'm wondering if there is a pd-vanilla friendly alternative to this 3rd
> party external.
>
> any hints?
>
> thanks in advance,
>
> ali
> ______________________________ _________________
> Pd-list at lists.iem.at mailing list
> UNSUBSCRIBE and account-management -> https://lists.puredata.info/
> listinfo/pd-list <https://lists.puredata.info/listinfo/pd-list>
>
>
>
>
>
>
> _______________________________________________
> Pd-list at lists.iem.at mailing list
> UNSUBSCRIBE and account-management -> https://lists.puredata.info/
> listinfo/pd-list
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puredata.info/pipermail/pd-list/attachments/20170718/1e5020fa/attachment.html>


More information about the Pd-list mailing list