Best Way To Format Save files

So I always used to use csv to save all my presets as they’re quick to load and separate splits them quickly, but when they’re quite large, they become unwieldy to keep track of.
So I’ve just started using Value to keep track of them, and because I want to add other related data to them, but the xml nodes seem really cpu heavy, and regexpr which does great splitting them is really slow when they change.
So what do you do?

can you provide examples for those cases please?

Attached is a patch that hangs vvvv using regexpr
Xpath seems pretty good actually, I think my memories were from the element etc nodes, they seem to use quite a few clicks for not much, or maybe I just dont know how to use them!

tests (15.9 kB)

k, while the expression you specified will not return anything for the data you provide that does not excuse the freeze (which appears even with a valid expression for your data).

second. the way you concat tag-strings is really oldschool and you should indeed use the xml nodes. so please do so and also provide a patch that you consider too slow so we can check it.

Ok try this one
using element is quicker, to format xml but only if the input doesnt change, it freezes v4 when it does.
Element split is slower than xpath.
There are also no help patches for these nodes and tbh I can only figure out xpath slowly and by use of its help patch, and when working with other patchers, using xml, everyone hits f1 when using it, except maybe Woei ;)
eg what is prune, whats are its other outputs?

It kind of brings me back to my title, of what is the best way of doing this?

test2 (150.0 kB)

in the meantime:

  • we have general info on the xml nodes on the xml page.
  • the Prune (XElement) has a helppatch in b31.2 already
  • many more of the xml nodes have a helppatch in the lastest alpha.

Seen the XMl page, not really that helpful tbh, it mainly says here are some xml nodes, they do stuff with xml! ;)

I hadn’t tried f1-ing prune, fair cop!
@name gets me my names but
@name, tag Doesnt give me the values stored between I get an empty output, does it support attribures in tags when getting the encloded text?
Otherwise prune would do it all :D

It is 5x6 times more ticks than an xpath though, for the clock watcher that I am!

I’ll check out the latest alpha

test3 (152.8 kB)

ah and i forgot to mention. alphas already have a new \girlpower\IO\File section that should give you some ideas regarding your actual question. see if the RAW route works for you.

So your saying the best way to save presets is RAW? and just as I was starting to like xml ;)

well…best…is what works best for you. give it a try and find out.

raw is nice, if you don’t need to read or edit as a human being. and you’re datalayout is kinda static.

for anotated data json or xml is still feels fine.

@cat: note the stuttering in test3 whenever you change the XElement xml is mostly caused by the use of the old xpath nodes which write the whole input into tty. disconnecting those it’s not completely gone in mainloop on raw, but on my machine invisible on filtered mode.

about prune: the xpathing in this one is quite strict. so in your case the XPath query should be something like //tag to fetch every tag. and the queries then can be @name and . (shorthand for self) to get the enclosed text

Thanks woei, the prune tips were exactly what I was looking for XML-wise the ticks arent too bad, and i can probably work around those.