| 690 | } |
| 691 | const size_t offset = frame * static_cast<size_t>(channels); |
| 692 | for (int64_t channel = 0; channel < channels; ++channel) { |
| 693 | const size_t index = offset + static_cast<size_t>(channel); |
| 694 | hidden[index] = next_timestep * noise[index] + (1.0F - next_timestep) * clean_src_latents[index]; |
| 695 | } |
| 696 | } |
| 697 | } |
| 698 | |
| 699 | std::vector<float> build_soft_repaint_mask(const std::vector<int32_t> & repaint_mask, int64_t crossfade_frames) { |
| 700 | return engine::sampling::build_soft_mask(repaint_mask, crossfade_frames); |
| 701 | } |
| 702 | |
| 703 | void apply_repaint_boundary_blend( |
| 704 | std::vector<float> & generated, |
| 705 | const std::vector<float> & clean_src_latents, |
| 706 | const std::vector<int32_t> & repaint_mask, |
| 707 | int64_t crossfade_frames, |
| 708 | int64_t channels) { |
no test coverage detected