MCPcopy Create free account
hub / github.com/0xShug0/audio.cpp / gaussian_noise

Function gaussian_noise

src/models/ace_step/diffusion.cpp:538–544  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

536}
537
538int64_t python_round_nonnegative(float value) {
539 if (value < 0.0F) {
540 throw std::runtime_error("ACE-Step diffusion expected a nonnegative value for Python-style rounding");
541 }
542 const double x = static_cast<double>(value);
543 const double floor_value = std::floor(x);
544 const double fraction = x - floor_value;
545 int64_t rounded = static_cast<int64_t>(floor_value);
546 if (fraction > 0.5) {
547 ++rounded;

Callers 3

renoiseFunction · 0.85
load_noise_or_sampleFunction · 0.85

Calls 1

Tested by

no test coverage detected