界面已本地化;技能介绍与说明文档按所选语言由 AI 自动翻译,代码、命令、路径和专业术语保留原文,以原作者文档为准。
探索技能
效率与协作 · SKILL.md

rectified_velocity_regression

rectified_velocity_regression

【效率与协作】Fit and audit a small rectified-flow velocity model with least-squares regression and optimizer evidence.

独立 GitHub 快照 · 自动分类 · 以原作者文档为准

技能说明

GitHub

name: rectified_velocity_regression description: Fit and audit a small rectified-flow velocity model with least-squares regression and optimizer evidence.

Rectified Velocity Regression

Use this skill when rectified-flow records must be converted into a trained velocity field or when recovery must prove that an optimizer step happened. Do not use it to construct interpolation records.

Inputs

  • Records with xt, t, and target_velocity.
  • Affine parameters w_x, w_t, and b per dimension.
  • A learning rate and optional step count.

Outputs

  • Loss before and after training.
  • Parameter values before and after training.
  • Optimizer-change evidence and gradients.

Workflow

  1. Evaluate v(x,t) = w_x * x + w_t * t + b per dimension.
  2. Compute mean squared error against target_velocity.
  3. Compute analytic gradients and update parameters with SGD.
  4. Report loss reduction and parameter changes.

Validation

Run python tests/test_velocity.py or validate with --run-tests.

Limitations

This deterministic affine model is intended for bounded recovery and unit tests; it is not a replacement for the paper's full neural image model.

我的收藏