Nodes/RyanOnTheInside/Feature Rebase βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜
ComfyUI Node

Feature Rebase βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜

Zoom into a slice of your feature's range and use the full 0–1 swing for just that

By ryanontheinsideΒ·Created 2 years agoΒ·Updated 5 months agoΒ· 852
Feature Rebase βš‘πŸ…‘πŸ…žπŸ…£πŸ…˜
  • feature
  • FEATURE
β—„lower_threshold0.00β–Ί
β—„upper_threshold1.00β–Ί
β—„invert_outputfalseβ–Ί

If your feature spends most of its time bunched up near the top of its range - loud audio that rarely dips below 0.7, say - the interesting variation is happening in a narrow band, and anything driven by the raw curve barely reacts to it. Feature Rebase fixes that: pick the sub-range you actually care about with two thresholds, and the node clips to that window and re-expresses it as the full 0–1 range, so subtle movement within your slice now uses the whole swing instead of being squeezed near one end.

If you're new to the RyanOnTheInside pack (Ryan / u/ryanontheinside, also behind ComfyStream and Daydream's real-time reactive video work): a FEATURE is a per-frame value curve, extracted from a source and reshaped by Feature Modulator nodes like this one before it drives a Flex node's parameter or an external target.

How it works

lower_threshold and upper_threshold define the window, both constrained to the feature's normalized 0.0–1.0 range. Anything below the lower threshold gets clamped to the bottom of the output, anything above the upper threshold clamps to the top, and everything in between gets rescaled so that window now spans the full output range. If you set lower_threshold = 0.7 and upper_threshold = 1.0, a feature that used to barely move (always between 0.7 and 1.0) now swings the full 0–1 based on where it sits within just that top slice.

Inputs and outputs that matter

  • feature (required) - the curve to rebase.
  • lower_threshold (0.0–1.0, default 0) - the bottom of the window you're isolating; clamped and mapped to 0 in the output.
  • upper_threshold (0.0–1.0, default 1) - the top of the window; clamped and mapped to 1 in the output.
  • invert_output - whether to invert the output feature values, per the node's own tooltip.

Output is a single FEATURE, wired into a Flex node's optional feature input or another modulator.

Installing it

Via ComfyUI Manager: search RyanOnTheInside. Manual install:

cd ComfyUI/custom_nodes
git clone https://github.com/ryanontheinside/ComfyUI_RyanOnTheInside
cd ComfyUI_RyanOnTheInside
pip install -r requirements.txt

Pure math on already-extracted feature data - no models, no GPU work, though it ships with the pack's full dependency set.

Where people get tripped up

If a v1-to-v2 update leaves the pack broken, the README's fix is a full uninstall and reinstall rather than a git pull.

The thing to know about this node versus its close cousin, Feature Renormalize: Rebase's thresholds are locked to 0–1, so it only ever isolates and re-expresses a slice within the feature's own normalized range. If you actually need to map a feature onto a different numeric range entirely - negative values, or a range wider than 0–1, for a downstream parameter that isn't itself 0–1 - that's Feature Renormalize's job, not this one; its thresholds go from -10,000 to 10,000. Reach for Rebase when the problem is "my feature's interesting variation is bunched up in a narrow slice," and reach for Renormalize when the problem is "my feature is 0–1 but I need it to be something else."

CategoryRyanOnTheInside/FlexFeatures/FeatureModulators

Inputs (4)

NameTypeDefaultDescription
featureFEATUREInput feature to be processed
lower_thresholdFLOAT0.000–1Lower threshold for feature values (0.0 to 1.0)
upper_thresholdFLOAT1.000–1Upper threshold for feature values (0.0 to 1.0)
invert_outputBOOLEANfalseWhether to invert the output feature values

Outputs (1)

NameTypeDescription
FEATUREFEATUREβ€”