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

Method run

src/models/heartmula/codec.cpp:1223–1244  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1221 ggml_gallocr_free(gallocr_);
1222 gallocr_ = nullptr;
1223 }
1224 throw std::runtime_error("failed to allocate HeartCodec scalar decoder graph");
1225 }
1226 }
1227 const HeartCodecWeightsRuntime * runtime_ = nullptr;
1228 int64_t batch_size_ = 0;
1229 int64_t frames_ = 0;
1230 int64_t output_samples_ = 0;
1231 std::unique_ptr<ggml_context, GgmlContextDeleter> ctx_;
1232 ggml_tensor * input_ = nullptr;
1233 ggml_tensor * output_ = nullptr;
1234 ggml_cgraph * graph_ = nullptr;
1235 ggml_gallocr_t gallocr_ = nullptr;
1236};
1237
1238HeartCodecWeights load_heartcodec_weights(
1239 const HeartMuLaAssets & assets,
1240 ggml_backend_t backend,
1241 core::BackendType backend_type,
1242 size_t weight_context_bytes,
1243 assets::TensorStorageType weight_storage_type) {
1244 require_assets(assets);
1245 HeartCodecWeights weights;
1246 weights.store = std::make_shared<core::BackendWeightStore>(
1247 backend,

Callers

nothing calls this directly

Calls 10

ggml_backend_tensor_setFunction · 0.85
set_backend_threadsFunction · 0.85
compute_backend_graphFunction · 0.85
ggml_backend_synchronizeFunction · 0.85
ggml_backend_tensor_getFunction · 0.85
sizeMethod · 0.45
dataMethod · 0.45
backendMethod · 0.45
threadsMethod · 0.45
resizeMethod · 0.45

Tested by

no test coverage detected