brummer10 / Ratatouille.lv2

Ratatouille is a Neural Model loader and mixer for Linux/Windows
BSD 3-Clause "New" or "Revised" License
60 stars 1 forks source link

Is it possible to control input level to each NAM model independently? #21

Open AtlantaScott opened 4 weeks ago

AtlantaScott commented 4 weeks ago

This is a feature request. I am interested in using two NAM profiles in parallel, but I am wondering if there could be a way to control the input levels to each NAM model independently. I find that in order to get the desired sound (i.e. the right amount of breakup) from each NAM that I have to carefully adjust the input gain. It is unlikely that two NAM models would require the exact same input level to achieve the desired amount of breakup. If there was an input control for each NAM file then I could do the fine tuning.

A related question, what is the location of the blend control in terms of signal flow? I was assuming it is located after the NAM models. Which of the following is describing the signal flow more accurately?: Input > Blend > NAM1/2 > Output Input > NAM1/2 > Blend > Output

I'm ignoring the IR's for the moment (I don't use IR's, just NAM), but my humble suggestion for gain-staging/signal flow is to remove the blend knob and instead have an input and output control for each NAM model. I believe an independent output control for each NAM model would be basically equivalent to the current "Blend plus Output" format. Myself I would find it more intuitive to have the following two sets of processing running in parallel:

Input 1>NAM1>Output 1 Input 2>NAM2>Delay>Output 2

I see the above as being essentially equivalent to these two lines running in parallel: Input 1>NAM1>Blend>Output Input 2>NAM2>Delay>Blend>Output

I believe the following two lines running in parallel describes the current version of the plugin: Input>NAM1>Blend>Output Input>NAM2>Delay>Blend>Output

I am assuming that this plugin is related to the Dual NAM option in Guitarix, which is the platform I use, and thus if it is possible to have independent input control for the two NAM models then it is also likely that it could be done in Guitarix as well. I was ideally hoping that I could use this LV2 plugin in Guitarix, which would give me the delay control (quite useful as NAM models seem to have very small delays built into them).

One final request would be to consider modifying the delay function to include both positive and negative delay amounts for the second model relative to the first. I am assuming the primary function of the delay is to phase-align or correct minor timing issues in each NAM model. If the only option is to delay the second NAM then one has to determine before hand which of the two models is early or late relative to the other, but this could be avoided if the delay knob on the GUI shows positive and negative values (default would be for delay knob to be at Noon with a value of 0). A 'negative' delay would be the equivalent of delaying NAM1 relative to NAM2 while a 'positive' delay would delay NAM2 relative to NAM1.

brummer10 commented 3 weeks ago

Some very good suggestions. I'll consider them all for the next development circle.

brummer10 commented 2 weeks ago

Okay, done. There is now a input control for each neural model and the delay control act now as a delta delay (negative values means first model, positive values means second model).

AtlantaScott commented 1 week ago

Wow, fantastic! Thanks for your effort! I was able to compile and run just fine. I can't load it in Guitarix, which I guess means the plugin doesn't meet requirements for Guitarix, but I think that's to be expected. In the big picture I was supposing that once all the dual parallel NAM issues were discussed/implemented here that one day you might be able to implement in the dual NAM guitarix version. I was able to insert it using Carla between mono and stereo Gtx but that's not an ideal solution. Meanwhile, I have another comment for you to consider regarding the delay function. After experimenting it seems to me that there are two different targets for delay compensation. One is for phase alignment (very fine tuned adjustment requiring single sample resolution) and Second is for longer delays perhaps inherent in the NAM or otherwise caused by issues in the capture. I found that with the 16 sample resolution in the current implementation that the range and resolution of delay could fix the second issue but not the first. In general I have relatively few issues with the second issue, but significant issues with phase alignment. When NAM trains the location of the 'blip' isn't super accurate and no matter what I do if I load two NAM models I captured they were just slightly out of phase. I think this has to do with the distortion of the blip in the recording and can't be helped since the amp is, well, distorted. On the other hand, I have seen some significant (ms) delays in some NAM's from online. I'm wondering which issue (phase vs. delay) is more common for folks. If it's phase then the delay could be changed to single sample resolution from 16, if it's delay it can be left the same, if it's both then that suggests one knob for each (or a toggle to switch from phase to delay function?). I'm not trying to add more and more controls to the interface, I'm just trying to describe what I'm hearing/experiencing and you can decide what is worth considering. Thanks for your hard work on this.

brummer10 commented 5 days ago

Okay, I've implemented support for the ctrl key (control) Now, when you press the ctrl key and dial the delay value it steps by one sample instead by 16. So you could dial it in sample accurate.

AtlantaScott commented 5 days ago

Super! I'll try this out. Seems like it should be able to let you set delay with the regular knob and phase with control. You can set delay first to get in the ballpark and then use control to do the fine tuning.