Page 2 of 3

Re: Ruby modules collection

PostPosted: Sat May 25, 2019 3:22 pm
by kortezzzz
Hi phill,

Thanks for the comment. My shame, but that's beyond my poor codding skills. Maybe one of our Ruby experts have an idea. Anyway, all those modules are collected. Non of them made by me. Wish I had the skills to make them by my self :|

Cheers

Re: Ruby modules collection

PostPosted: Sat May 25, 2019 4:40 pm
by trogluddite
Phil Thalasso wrote:May I ask the question, whether anybody would know whether it is possible to program a ruby module that gets triggered by some input (poly for example) and the adds a probabilistic value from a normal distribution to it.

I'll split that into two questions...

1) Can a Ruby event of some kind be triggered from audio?
Kind of. Doing it with sample precision is very CPU intensive though, as it would require turning audio streams into Ruby frames. Doing it in a "CPU light" way would be no more precise than doing it with 'green' (i.e. not very precise at all!) And Ruby can't interface with poly streams at all, so it would be no use for MIDI generated voices in synths.

2) Would the normal distribution algorithm require Ruby?
Very precise algorithms probably would need Ruby features (e.g. "while" or "until" loops). However, for the given application, a reasonable approximation of the distribution will most likely suffice. Approximated algorithms tend to struggle the most with the rarest values at the far ends of the distribution "tails" - but since sequencer parameters are bounded, you don't need the tails to extend very far; in fact, it would be better that they didn't. A very efficient approximation can be done by passing a uniformly generated random number through the quantile function for the desired distribution, which could be implemented as an interpolated look-up table in green, poly or mono (and would allow approximating any distribution that you wanted.)

Re: Ruby modules collection

PostPosted: Mon May 27, 2019 6:17 am
by Phil Thalasso
Good morning everybody and thank you Trogluditte for your detailed answer.
It helped my thought process.
I assume that I 'll now search for a ruby recipe for a typical statistics 101 nail-board.
Maybe that can even be done with prims.
The idea behind all that is, that I want to construct a "pseudo-random sequencer".
Say you have a sixteen step sequencer that you set the values for each step with a knob.
(Like in Spogg's A.S.S.. Since about a year I am working on an optical pimping of this
wonderful instrument - with Spogg's express permission and a lot of support from him.)
What I want to happen in the sequencing part is the following:
You set the sequencer for example to all C3s. Once you press a key, a pseudo random decision
will be made, which note is actually played. The intervals would have probabilities assigned
to them and the interval-structure by itself could also be set. One idea was, to have one of the basic
structures follow a normal distribution N(0,phi), with phi being driven by an Lfo. Might result in
CPU above 100%.
Anyhow, Trogluddite, with your input I'll try to work something out in which the levels of the nailboard
can be adjusted (instances of probabilistic decisions).

You all have a good day

Best Regards
Phil

Re: Ruby modules collection

PostPosted: Sat Jun 01, 2019 5:12 pm
by Halon
Tanks guys. I can learn a lot from these ;)

Re: Ruby modules collection

PostPosted: Mon Jun 03, 2019 5:08 am
by billv
Hope these come in handy.. :)
BV_Ruby_Collection.fsm
(1.8 MiB) Downloaded 491 times

Re: Ruby modules collection

PostPosted: Mon Jun 03, 2019 6:56 am
by Spogg
billv wrote:Hope these come in handy.. :)


Excellent, thanks!

Spogg

Re: Ruby modules collection

PostPosted: Mon Jun 03, 2019 7:40 am
by RJHollins
Thanks billv !

Re: Ruby modules collection

PostPosted: Mon Jun 03, 2019 8:48 pm
by kortezzzz
A huge "thank you" has been sent to you from my toolbox, billv ;)

Re: Ruby modules collection

PostPosted: Thu Jun 20, 2019 10:57 pm
by Nubeat7
here are several links to some ruby projects of mine:
- cablepatcher:
viewtopic.php?f=3&t=2916
- toolkit (mostly ruby):
viewtopic.php?f=3&t=6383
-class array expansion:
viewtopic.php?f=3&t=1760
-xy pad:
viewtopic.php?f=3&t=14154
- ruby knob:
viewtopic.php?f=3&t=641
- circular stepsequencer:
viewtopic.php?f=3&t=6268
- prestmanager with groups:
viewtopic.php?f=3&t=2477&hilit=+presetmanager

and welcome back Mr Trogluddite ! good to see you again :) a tiny structure i extracted from one of your projects made a huge impact in some of my projects, i called it "zero at request" which sets the output to zero when a reverse trigger arrives. just one of many great influences your schematics and your support had on my journey with FS , thanks for that :)
viewtopic.php?f=3&t=3520&p=19412&hilit=zero+at+request#p19119

Re: Ruby modules collection

PostPosted: Fri Jun 21, 2019 12:54 am
by RJHollins
always good stuff from NuBeat.

Big Thanks !