Archived
krea2: rebalance, the text taps at ConditioningKrea2Rebalance's gains
A request may ask for Krea 2's twelve text taps to be multiplied by fixed gains before the text fusion, as ComfyUI's ConditioningKrea2Rebalance (nova452) does at its defaults: multiplier 4 times the per-layer weights 1, 1, 1, 1, 1, 1, 1, 2.5, 5, 1.1, 4, 1. `rebalance: true` on /v1/images/generations (JSON or form) sets RAD_GEN_COND_REBALANCE in RadGenBatch::cond_opts, appended in ABI 26; the plugin then scales each tapped layer's rows into te.h2 with chan_affine (f32, rounded once) and scatters those instead of te.x, so the residual stream is untouched. Without the field every pass issues exactly what it did before; other models ignore it. The gains cannot be folded into weights: the taps enter the fusion's layer-wise blocks raw, through a pre-norm residual. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
7aa51e5b4a
commit
123c439684
8 files changed
+76
-5
No files matched your search
@@ -816,6 +816,7 @@ const RadBatch* Driver::build_cond(Job& j, int branch, int step) {
|
||||
G.aux_cu = n_aux ? dptr<int32_t>(ri, R_AUX) : nullptr;
|
||||
G.aux_ids = n_aux ? dptr<int32_t>(ri, R_AUX) + 2 : nullptr;
|
||||
G.tokens_h = hptr<int32_t>(R_TOK);
|
||||
G.cond_opts = j.req->cond_opts;
|
||||
if (joint()) {
|
||||
B.n_kv_groups = 0;
|
||||
B.kv = nullptr;
|
||||
|
||||
Reference in new issue
Block a user