• weightless

    @ingox Oh I see, well at this point it's not likely to get much simpler than this I reckon, and it's probably fast enough even with very large inputs.

    posted in technical issues read more
  • weightless

    @ingox Great work, thanks for sharing. Great idea to include the state saving mechanism, in fact that subpatch can be taken as a nice starting point for state saving that requires a specific order of execution. As far as I'm concerned, of course you or anyone else can do whatever they want with the code I posted, which in turn was taken from somewhere else as you mentioned.

    Out of curiosity, you say it's 300 times faster compared to which patch? Sounds like an amazing improvement.

    posted in technical issues read more
  • weightless

    @cfry I'm not aware of any other that explains it as well as the FLOSS manual. Once you have the basics from that, I suggest you look at the help files for [list] and [array] to get to know all the new objects and what they do. The List-abs library also has lots of helpful abstractions to do operations on lists.

    Sorry, you probably know all this already. Is there something in particular you don't understand that the manual doesn't cover?

    posted in technical issues read more
  • weightless

    @cfry As far as I know there is no easy way to shift the whole array so it might be easier to just build a list:Screenshot 2019-07-14 at 18.29.51.png

    list_building.pd

    posted in technical issues read more
  • weightless

    @gmay What version of Pd are you using? In the newer versions to install zexy just go to menu > Help > Find externals, type zexy and click on the first hit (2.2.8 Darwin). Then go to menu > Pd > Preferences > Startup.., click "new" and type zexy. Restart Pd and you should be able to use the objects from the library.

    posted in technical issues read more
  • weightless

    @RetroMaximus As @Jona said, text is very flexible because you can not only address lines by index, but also individual fields in each line. It makes more sense to use only one text object, unless you want to save different "presets" for each sequencer line, but even that could be worked around.

    I'll throw an idea (which might not be applicable in your case) which is to take advantage of the fact that lists of zeros and ones can be expressed (and therefore stored) as the binary version of an integer, and convert to and from its binary equivalent. binseq-help shows a simple application of that.
    bin_sequencer.zip
    (the abstractions are called "bin2f" and "f2bin", but in fact they work with integers only).

    posted in technical issues read more
  • weightless

    @Jona It's a very useful little abstraction, I'm trying it out with some real data to see if there are any errors still.
    I had to add a receive from the stored order object before the moses for [make(, this way when re-making the chain after it has been saved in a parent patch, the number of indices is checked against the correct order that was stored.

    markov-poly4.zip

    One annoying limitation of the way I've implemented state saving in these abstractions is that there is no way of keeping track of the order in which the saved parameters/arrays/texts are loaded. I have no idea how to do that reliably, otherwise it would be easier to just store and load the indices and memory texts first, then load the stored order and re-make the chain on loading.

    posted in technical issues read more
  • weightless

    @ingox Here it is with state saving. If you open the help patch and click the two iterate bangs you'll see that the two abstractions are saved with different chains of different orders. If there is no state to load, the order initialises to 1.

    markov-poly3.zip

    I had to change a few of things connected with the order, the most significant is that rather than automatically clipping the order according to the length of the indices text, I think it makes more sense to give an error if the input source is too short for making an nth order chain. That is, if I send [order 3( but there are only 3 lines of text, I wouldn't like the abstraction to silently make a second order chain instead.

    EDIT: updated zip

    posted in technical issues read more
  • weightless

    @ingox State saving works only if one (or more) instance of the abstraction is loaded in a parent patch. When you save the parent patch, all abstractions dump the content of their tables which get saved in the parent .pd file, each linked to the instance of the abstraction that sent it. when you re-open the parent patch, those saved tables are dumped back. Nothing is stored in the abstraction itself, so if you open the abstraction file nothing gets recalled and so the tables are initialised as empty (you mustn't use the -k flag).
    I suppose it could be disabled but I can't think of any scenario where that would be advantageous.

    I've recently made these abstractions which I use all the time and have made my pd life so much easier I don't even remember what it was like before.
    https://forum.pdpatchrepo.info/topic/12066/store-state-patch-less-state-saving-method-for-abstractions/9

    The only difference in our markov patch is that the order cannot be set with an argument anymore because if you create the object [markov 3], then send it the message [order 2(, and save the parent patch, the text is saved containing a second order markov chain, but when you open the parent again it loads the argument 3. In fact I think it's not ideal to set the order in the argument.

    I hope this makes sense, I'll post a modified patch to show this.

    posted in technical issues read more
  • weightless

    @ingox Perfect!
    This is your patch with the simplification I mentioned, I also changed the text names so they make more sense (hopefully?).

    markov-poly2.zip

    I'm wondering if you'd include state saving in this simple abstraction, it's basically the same as using the text define -k flag but multiple abstractions can hold unique chains.

    posted in technical issues read more

Internal error.

Oops! Looks like something went wrong!