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

Function round_up_to_multiple

src/models/stable_audio/same_autoencoder.cpp:40–45  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38constexpr float kPi = 3.14159265358979323846F;
39
40int64_t round_up_to_multiple(int64_t value, int64_t multiple) {
41 if (multiple <= 0) {
42 throw std::runtime_error("Stable Audio SAME alignment multiple must be positive");
43 }
44 return ((value + multiple - 1) / multiple) * multiple;
45}
46
47int64_t decoder_graph_latents(const StableAudioConfig & config, int64_t latent_tokens, bool chunked) {
48 if (chunked && latent_tokens > kSameChunkLatents) {

Callers 1

decoder_graph_latentsFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected