Python class
YarnScalingParams
YarnScalingParams
class max.nn.YarnScalingParams(factor, beta_fast, beta_slow, original_max_position_embeddings, truncate)
Bases: object
Scaling parameters for YaRN (Yet another RoPE eNhancement) frequency interpolation.
-
Parameters:
beta_fast
beta_fast: float
Yarn parameter for fast frequencies.
beta_slow
beta_slow: float
Yarn parameter for slow frequencies.
factor
factor: float
Main scaling factor for the frequency components of the rope.
original_max_position_embeddings
original_max_position_embeddings: int
The original maximum position length supported by the model.
truncate
truncate: bool
Whether to truncate the frequencies or not.
Was this page helpful?
Thank you! We'll create more content like this.
Thank you for helping us improve!