Analog Obsession looking for new owner

DSP, Plug-in and Host development discussion.
Miles1981
KVRian
1366 posts since 26 Apr, 2004 from UK

Post Thu Dec 06, 2018 11:48 am

ghettosynth wrote:
Thu Dec 06, 2018 8:52 am
I'm familiar with Faust, I have done a few prototypes with it, but AFAIK there is no tool that generates Faust code from a circuit model that is publically available, right? So that can only be a part of the story here. FWIW, I'm less interested in the OPs drama than I am in useful open source tools so if I've missed something then I'm all ears.
There is a tool that dynamically create a filter, like Halite did, and I have an static version (generating code and running it in JIT), but closed source.
The complex part, of course, is writing the solver efficiently.
Izak Synthiemental wrote:
Thu Dec 06, 2018 9:43 am
There is also a tool that (in a future update) promises to be able to turn Spice circuit modelling directly into VST plugins.

http://www.livespice.org/
That's already handled by Audio ToolKit - Modelling-lite (the dynamic filter generator).

stratum
KVRAF
2114 posts since 29 May, 2012

Re: Analog Obsession looking for new owner

Post Thu Dec 06, 2018 1:38 pm

mystran wrote:
Thu Dec 06, 2018 10:22 am
stratum wrote:
Thu Dec 06, 2018 9:46 am
mystran wrote:
Thu Dec 06, 2018 9:20 am
Burillo wrote:
Thu Dec 06, 2018 8:26 am
i don't think competition uses much of "hand written optimized assembly code" as much as you think. the problem isn't lack of hand-written assembly, it's lack of hand-written code (as opposed to generated one) :)
Yeah, anyone serious about circuit modelling is shooting themselves in the foot with a nuclear warhead if they are trying to write their solvers manually. It's a huge waste of time and you end up with slow code, because several useful optimisations are just far too labor intensive and error-prone to even consider if you have to do it all manually.
So.. dump the traced execution of the code that the solver was executing to a text file (assuming the decisions are fixed) and let the compiler optimizer handle that. I recall you had mentioned something like that.
That will get you started, although you can take it further. For example, you can optimise the order in which you solve the circuit, such that you can pre-compute the solution (but don't do it until you know your sampling rate, so you can treat that as constant too) as far as possible and keep the inner Newton-loops as small as possible (you don't want to iterate the full circuit for those). Stuff like that. It's not rocket-science, but it's stuff that you really don't want to do manually (because the resulting code makes no sense when you look at it) and which benefits from domain specific knowledge (ie. it's unrealistic to expect the compiler to do the right thing without some help).
Is there any case the solver takes different paths of execution, resulting different contents in that text dump file? i.e. if node 1 voltage is below X, then the circuit behaves roughly linear and use the function generated from text dump file 1, otherwise use the one from text dump file 2 etc? It looks like one could check several such conditions depending on the circuit.
edit: oh and you probably don't want to build MNA matrices by hand either, since it's pretty to stamp them automatically from a net-list or similar
yes, I recall that too. those values across the diagonal.
~stratum~

User avatar
VariKusBrainZ
KVRAF
8680 posts since 16 Dec, 2002

Re: Analog Obsession looking for new owner

Post Thu Dec 06, 2018 1:49 pm

Izak Synthiemental wrote:
Thu Dec 06, 2018 9:43 am
There is also a tool that (in a future update) promises to be able to turn Spice circuit modelling directly into VST plugins.

http://www.livespice.org/
That has been promised since many years and is yet to materialise

mystran
KVRAF
5031 posts since 12 Feb, 2006 from Helsinki, Finland

Re: Analog Obsession looking for new owner

Post Fri Dec 07, 2018 5:50 am

stratum wrote:
Thu Dec 06, 2018 1:38 pm
Is there any case the solver takes different paths of execution, resulting different contents in that text dump file? i.e. if node 1 voltage is below X, then the circuit behaves roughly linear and use the function generated from text dump file 1, otherwise use the one from text dump file 2 etc? It looks like one could check several such conditions depending on the circuit.
Yeah, there can be a few "corner cases" like that.

Most obvious case is where ideal switch will unify two nodes into one when connected (reducing MNA matrix dimension by one). You could cheat and treat them as very low value resistors instead (after all, wires do have some resistances in real-life), but even then you have to be careful not to pivot LU on those, because in disconnected states your conductance would be zero (although you could treat those as very high value resistors; could be reasonable for semiconductor switches, but not really for mechanicals).

So for switches (ie. "intentional topology changes") you might want to compile multiple versions depending on the configuration of switches. The strategy of adding small series/parallel resistances is pretty good at taking care of "accidental topology changes" with time-varying components though (and you probably need this stuff for robust Newton convergence anyway). Since static resistances can usually be constant folded away, this doesn't usually cost anything either.

The remaining problem then is when you end up choosing LU-pivots that turn out to be numerically very poor after dynamic values in the circuit change. This is not nearly as much of a problem in practice as one might think (as-in: it's actually hard to find good test cases), but it's something that I don't have a completely reliable solution for. For any given circuit, there is usually a pivoting order that is "universally good enough" that you can just set in stone, but finding that order might occasionally take some trial and error.

My current best strategy for the pivoting problem is to simply do a "test run" of the circuit normally, with pivoting heuristics that try to keep the order from the previous time-step/iteration unless there is a much better choice available. Surprisingly enough, this usually finds a stable order pretty quickly (and for most simple audio circuits it just picks the pivots once and never changes them afterwards), but it's not exactly what I'd call a "robust solution."

Anyway.. the thing is.. even if you were doing this stuff "manually" you'd still have to solve all these problems. :)
If you'd like Signaldust to return, please ask Katinka Tuisku to resign.

mystran
KVRAF
5031 posts since 12 Feb, 2006 from Helsinki, Finland

Re: Analog Obsession looking for new owner

Post Fri Dec 07, 2018 6:13 am

Another strategy that I haven't tried, but which seems reasonable in theory (and I suspect someone has probably tried this): once you've separated the non-linear parts, you could build a multi-variate approximation for that block directly. That would kill two birds with one stone: it would get rid of Newton iteration and it would avoid all the pivoting concerns (because you'd no longer be using LU for the dynamic parts of the matrix).
If you'd like Signaldust to return, please ask Katinka Tuisku to resign.

quikquak
KVRist
424 posts since 6 Aug, 2005 from England

Re: Analog Obsession looking for new owner

Post Fri Dec 07, 2018 6:59 am

This is interesting and all, but WAAAY off topic.... :)
So, AnalogObsession why are you selling up? We're all (probably just me) itching to know what the 'serious reasons' are.
Plus you're NOT saying it might be that the business has failed?... Which is probably inducing some scepticism around here.

Dave.

Return to “DSP and Plug-in Development”