On Sat, Sep 20, 2014 at 04:10:13PM -0400, Mark D. McCurry wrote:
> On 09-20, Fons Adriaensen wrote:
> > Having to do 256 1024-point FFTs just to start a note is insane.
> > It almost certainly means there is something fundamentally wrong
> > with the synthesis algorithm used.
>
> I agree with that notion.
> In typical patches something between 2-10 IFFTs is expected and even this
> cost strikes me as too high (zero IFFTs for pure PAD/SUB synth based).
> In terms of worst case scenarios ZynAddSubFX can have some rather insane
> characteristics given multiple parts, kits, voices, etc.
> For instance if a user decided to use all padsynth instances at max quality,
> they would need 12GB of memory just to store the resulting wavetables.
>
> Such extremes are not really seen in practice, but things are slowly getting
> optimized to avoid them when possible.
You should really look at this from an information theory POV,
combined with some psycho-acoustics.
Suppose you have to deliver 256 samples in a period when a note
starts. That amounts to around 5.3 ms at 48 kHz. That time limits
the amount of spectral detail that can be detected given the
output from the first period. Which means that there is no point
in generating more detail in the first period of a note.
Even on sustained notes the amount of spectral detail that can be
detected by a human listener is limited by the critical bandwidth
of human hearing (which increases with frequency). That means that
any set of harmonics that fall within a critical bandwidth can be
replaced by a single one with the same energy and nobody would be
able to hear the difference. All this means that you *never* need
256 harmonics, not even on bass notes below Fs / (2 * 256).
And if the final output is a weighted sum of those IFFT outputs
you can as well compute the weighted sum of the inputs and then
do a single IFFT - it's a linear transform after all.
Ciao,
--
FA
A world of exhaustive, reliable metadata would be an utopia.
It's also a pipe-dream, founded on self-delusion, nerd hubris
and hysterically inflated market opportunities. (Cory Doctorow)
----- End forwarded message -----
--
FA
A world of exhaustive, reliable metadata would be an utopia.
It's also a pipe-dream, founded on self-delusion, nerd hubris
and hysterically inflated market opportunities. (Cory Doctorow)
On 09-20, Fons Adriaensen wrote:
> Having to do 256 1024-point FFTs just to start a note is insane.
> It almost certainly means there is something fundamentally wrong
> with the synthesis algorithm used.
I agree with that notion.
In typical patches something between 2-10 IFFTs is expected and even this
cost strikes me as too high (zero IFFTs for pure PAD/SUB synth based).
In terms of worst case scenarios ZynAddSubFX can have some rather insane
characteristics given multiple parts, kits, voices, etc.
For instance if a user decided to use all padsynth instances at max quality,
they would need 12GB of memory just to store the resulting wavetables.
Such extremes are not really seen in practice, but things are slowly getting
optimized to avoid them when possible.
The biggest flaw in the algorithm besides the current high cost of
initialization is the use of some adaptive harmonics routines which do some
frequency dependent spectral modifications before the IFFT.
More or less that chunk of math will end up resulting in some inaccuracies when
converting to any normal wavetable representation which will avoid the IFFT.
Changing over to a wavetable approach will make other parts of the algorithm
more correct than they currently are, but there's tradeoffs between correctness
and consistency between versions.
--Mark
(Oops, it looks like I missed the ML the first time I sent this)
Hi, as mentioned in subject: Production release 0.4.2 planed of Advanced
Gtk+ Sequencer.
Now, comes your part I would like you to test functionality. I'll do for
you a wiki page of aspects to test.
Please visit http://ags.sf.net and wiki page
https://sourceforge.net/p/ags/wiki/testing-cheatsheet/
Happy to hear of you pretty soon!
Joël
I thought I would move this over here. I know there is already work being
done on this hw wise. These thoughts are for a point to point raw
ethernet audio transport That still allows some normal network traffic as
well.
On Tue, 2 Sep 2014, Len Ovens wrote:
> My thought is something like this:
> We control all network traffic. Lets try for 4 words of audio. For sync
> purposes, at each word boundry a short audio packet is sent of 10 channels.
> This would be close to minimum enet packet size. Then there should be room
> for one full size enet packet, in fact even at 100m the small sync packet
> could contain more than 10 channels (I have basically said 10m would not be
> supported, but if no network traffic was supported then 10m could do 3 or 4
> channels with no word sync). So:
> Word 1 - audio sync plus 10 tracks - one full network traffic packet
> word 2 - audio sync plus 10 tracks - one full audio packet 40 tracks
> split between word 1 and 2
> wors 3 - audio sync plus 10 tracks - one full audio packet 40 tracks
> split between word 2 and 3
> word 4 - audio sync plus 10 tracks - one full audio packet 40 tracks
> split between word 3 and 4
Nobody commented that this could not work :) 4 samples on a 100mbit link
is still less than one full 1500byte data packet. The reason I am thinking
about this right now, is that my studio has been flooded :P and so I
have no access to work on my control surface project right now.
So some background thinking:
- The idea is to replace FW audio interfaces with something at least as
good, maybe better.
- Really low latency available (even if a lot of uses don't need it)
- Really stable operation. On a desktop/rack computer where the
user has access to a PCIe slot, it is obvous that a second NIC would be
the best solution. Laptops should work too.
- Normal network traffic will make it through this mess without ever
disturbing the audio. A laptop may be used with only one NIC and still
need to access network traffic.
- It should "just work" on newer network hw as it is developed.
- It should handle a switch in the middle for use as a range extender, but
never as a network traffic mixer. (on a 1gbit link other traffic may not
disturb things with low enough channel count) What I have thought of so
far would tend to ignore other traffic anyway and a switch should end up
just sending our traffic through our ports. This situation may require
some user intervention such as pointing out which box they wish to connect
to.
- It should deal well with hot plugging. This feels messy, but it should
be possible to let things like netman play with things first and still be
able to detect an audio IF has been connected and reinit the interface for
this use.
In the end, the kernel module for this device should be loaded anytime a
NIC is detected. (detected and has a connection) It should create both an
eth* device and an ALSA device, but should only do so if it detects an
audio IF online. To begin with, this would mean the user would have to do
some setup to get around all the auto setup stuff already running (dhcp
etc.) But as the IF was used more, normal networking stuff might be
expected to detect an audio IF and leave it alone. Maybe the audio IF
could have a dhcp server that refused an IP so that the dhcp client gives
up and goes away. That is, use network protocols that are already
available when possible.
This whole effort assumes the ethernet device is connected by twisted
pair from the host computer to the audio device with a separate path for
each direction. This is very important as it _should_ make for a colision
free environment. This interface will control both audio and data flow.
Any network traffic will only be sent during times audio sending is not
needed. This can be done because all network data will go through the
audio driver. There are still a lot of 100mbit networks out. Lots of new
equipment still has them too. I have chosen a 4 sample frame at 48k (which
happens to be 16 samples for 192k... if you must) because it seems to be
the lowest latency with reasonable use of overhead. (on Gbit and higher
lines, this is no longer true. The internet still runs on 1500MTU and more
than one full packet will travel in one sample's time) I have done all my
calculations based on a 100mbit line because that happens to be what I
have to play with and appears to be able to handle up to 60 audio channels
with some left over for control. I understand that there are venues that
use more, but gbit links will handle lots more. (600 plus, but realize the
systems on each end have to be able to deal with the data as it comes in,
it is not just about the link capabilities)
So, My thought is that each group of packets sent will be timed by a group
of 4 samples. The driver will attempt to send a packet with 4 samples
worth of audio for all channels at the end of those 4 samples. The driver
then calculates how much time it has before another 4 sample times are up
and sends as much data as it has time for. This calculation should be able
to happen only one time for any channel number setup if the hw is not
doing anything too fancy (like waiting for more than one packet before it
sends). It assumes the hardware/driver uses standard size guard bands,
etc. SO for each 4 samples there would be two packets minimum (probably
maximum too for a 100m link). One audio and one data. On a 100m link these
packets would always have an mtu of less than 1500. It would not be
possible to use the arrival of an audio packet as a sync signal, sync as
always, would be an external line if two audio interfaces needed to be
used.
I expect to have an atom based MB to play with soon that has two NICs on
board. as well as an audio IF. This will not be a true test low latency
because the onboard AI has higher latency to begin with (runs at p64/n3
min) and so I will have 192 samples to play with at a time which I will
still try sending in 4 sample bundles. (I may try putting an older PCI AI
in to see if I can get that down a bit) My thought is to make the AI side
a jack client (I think I can do that much :) and the host side an ALSA
device (something new to learn).
All control will be MIDI-able. Because there is two NICs and one of them
expects to do real IP based networking, OSC is possible as well as web
based control. IN the end this is also a general computer running Linux
that can be SSHed into (even ssh -Y) almost anything is possible... but I
would guess the first box that has a real DIY digital CODEC, S/pdif, ADAT
or MADI IF will be pretty basic.... but looking at the R-Pi, basic seems
to be pretty powerful anymore.
In the long run this could be a very interesting device. There is no
reason this could not also be, an effects box (both with local analog
ports as well as through net), a softsynth (most of these boards have at
least one serial port or USB), A remote mixer... drop the box FOH and use
a networked control surface, Android pad... even a browser to control, a
FOH snake box or even a standalone recording device.
Price point? Concidering ethernet switches, USB AUdio devices, Ethernet
storage controllers, set top... I hesitate to call them boxes some of
them are so small? Even development boards look ok. I don't think It would
be worth while to make a two i/o box, but by the time we hit 8 or so it
begins to look good.
--
Len Ovens
www.ovenwerks.net
Hi,
is it correct that the following two scenarios give the exact same result?
(digital audio signal) -> (record) -> (playback) -> (apply fx) -> (result)
(digital audio signal) -> (apply fx) -> (record) -> (playback) -> (result)
regards
Tom
> Partly also for historical reasons, I think. In many ways digital
> recording started as the "poor man's tape". Direct to disk recording with
> no effects was at first all that could be handled and most peole using it
> were replacing 8 track tape with it. They already had a mixer. As the DAW
> developed, mix down on the computer has been next. But for many people the
> recording part of the strip has been outside of the DAW, on an analog
> mixer. This is changing as a new batch of people are going mic->
> interface. Their input strip is whatever the interface provides... often
> only trim (either as a pot on the pre or in ALSA).
Is this for convenience or not having the ability to afford something else?
I think a lot of times money is spent on the wrong thing such as buying a
fancy multicore computer when something from 8 years ago is totally adequate
for digital audio.
>
> So digital recording is
> also going through a two mixer to inline transition. From hybrid to
> digital only. The trim controls are there, where they should be, as close
> to incoming signal as possible. I don't suppose it would be too hard to
> add alsa trim for a card like the d1010 to ardour, but many USB IFs (even
> PCIe) have no controls in alsa. It is a physical pot somewhere. So rather
> than being in front of the engineer, it is hidden and easily missed by the
> newby... or even not so new. So much is done digitally, that the remaining
> analog items are forgotten. This is a real problem with a two input IF,
> The trim needs to be set every time and the variety of signals through one
> channel is huge. Everything from a ribbon to line level. Having a set of
> good pre amps could be worth while, this is probably the biggest hole in
> the hobby studio. I have two, tube and solid state. (plus line)
It is very simple to keep a few notes on what is a good preamp setting for
a given mic and preamp combination. One inconvenience with some budget
preamps is that you don't know what sort of gain it is providing, so while you
may write down the setting by using a notation like 2:00 for dial position,
you haven't learned anything about gain, so if you swap out a preamp you need
to guess at where to start.
You can get into trouble with a mismatch between preamp and converters, such that
you are trying to "maximize bits" by getting a hot signal level into your converters.
The preamp ends up distorting and you have a hi-res recording of a distorted sound!
I actually had this problem with a remake of a vintage preamp. So it seems every
preamp has a voltage sweet spot that it should be operated in.
The best situation is if you have converters with analog trims, which is I think
what you were saying, and set them accordingly for each preamp. I leave my preamps
plugged into a specific A/D channels that have been calibrated for that preamp.
One other note, some budget preamps are not qualified for certain levels of input.
I have a Presonus Audiobox which can sound fine for an acoustic guitar, but throw a
drum at it and it is automatically over full scale and unusable.
Grekim
Hello,
I'm currently working on a feature for Hydrogen to have multi banks
per instrument.
In a nutshell, if you have drum samples with direct and overhead
recordings, you can put those together under the instruments - one
instrument Snare for example with the band direct and the bank
overhead).
In the Hydrogen mixer, you can chose how much direct or overhead is
needed, changing completely the tone of the drums.
You can chose how many banks you have per instrument, and the gain of
each bank in a given instrument.
A very (very very.......veryveryvery) early version is available here:
https://github.com/blablack/hydrogen
Very early version as the main feature works, but for example I highly
doubt saving/loading songs would work just yet and the mixer GUI goes
a bit crazy when banks are added/removed, I'm in the process of a
massive testing/bug hunt...
I would be very interested to get some early feedback, both on the
feature and (for the most courageous) on the code itself.
Thanks in advance ladies and gentlemen!
Aurélien
> On 09/03/2014 04:04 PM, Raphaël BOLLEN wrote:
>> Hello,
>>
>> I'm trying to use jack_set_xrun_callback to be notified in my
>> application of eventual xrun.
>>
>> in the documentation of the function I see a note: that 'this function
>> cannot be called while the client is activated'.
>>
>> Does it mean that my client must call jack_set_xrun_callback before
>> being activated
>
> Yes. First set the callback, and only later call jack_activate().
>
>
> Two tiny jack clients which may come in handy:
>
> * jackxrun: report x-runs on the command line
> * busyjack: create artificial load
>
> http://gareus.org/gitweb/?p=jackfreqd.git;a=tree;f=tools;
> gcc -o jackxrun jackxrun.c -ljack
> gcc -o busyjack busyjack.c -ljack
>
> ./jackxrun # reports xruns in the terminal
> ./busyjack 90 # will ramp things up to 90% DSP load (default is 50)
>
> It can be used to create x-runs, yet it's not the same as a x-run from hw.
>
> [..]
>> It says return 0 on success. Does it mean the callback must succeed.
>
> Your callback function must return 0.
>
> Cheers!
> robin
Thanks Robin for your explanations and tools.
I think the x-runs (one every few hours) I get are due to hardware because jack_cpu_load is < 5% and
system load average < 0.2 all periods. The problem is that those xruns make the process thread jump
to 100% cpu and the process disappears from QJackctl, although jack and other clients still run
normally. The code also runs fine on another computer.
I'm currently testing with jack priority raised from 40 to 70 to be above irq threads. I did not yet
have an xrun in this config but It's a bit early to conclude.
I will also try busyjack.
Best regards
--
Raphaël.
Hi, I'd like to get some feedback here in LAD.
On September 3, 2014 07:44:55 PM Fons Adriaensen wrote:
>> On Wed, Sep 03, 2014 at 11:57:05AM -0700, J. Liles wrote:
> > (when I go from recording to mixing I usually change the JACK buffer
> > size... is NSM supposed to do this for me automatically? I don't see how
> > or why it would).
> RE switching buffer sizes, if your system works reliably with some
> size, there is no reason to use a larger one.
Did Paul say recently Jack's buffer size change system was never implemented?
Do I recall correctly that there is no way to switch?
Is the difficulty with internals, or conceptually? Or compatibility - how about:
If any client in the graph doesn't implement the callback or the callback
returns false, simply don't switch buffer size. Zero compatibility issues?
*** Usage Scenario 1:
You start your favourite DAW with what seems a moderate Jack buffer size.
As you work, you start adding effects to various tracks.
But you go too far, adding one too many CPU intensive plugins,
say Phase Vocoders and so on, and now you have at best xruns,
at worst slowness/freezing.
Now you must shut the app down, shut Jack down, adjust Jack's buffer size,
restart Jack, restart the application.
In light of the Pulse-on-Jack-QJackCtl threads these steps may not be easy.
Pushing an app button to be able to quickly switch to a higher buffer size
would be cool !
*** Usage Scenario 2:
J. Liles pretty much just said what I wanted to say:
During (but not limited to) recording, if you require to be able to monitor
one or more live inputs, low latency small buffers are absolutely required.
When I say monitor, I mean WITH effects plugins, otherwise hardware
monitoring can be used.
Here the DAW is being used as BOTH a recorder and an effects unit.
I do it a lot and it's a PITA to have to keep restarting with a new size.
After recording, when live input is no longer needed, we no longer care
about the buffer size and in fact DEMAND high latency higher buffer sizes.
The caveat here is that when switching to the 'live' low-latency mode,
we often have to first turn off some CPU-hungry plugins (non-essential on
playback tracks) and save the song before switching, otherwise after the
switch the app is slow/locked/frozen.
Then after switching back to non-live high-latency mode, we can safely
turn on those plugins again.
So we absolutely need those higher buffer sizes too sometimes.
I've been dreaming of having such a dual 'mode' switch in MusE.
>From lazy to tight at the push of a button.
Possible?
Thanks.
Tim.