| 356 | |
| 357 | ggml_backend_t backend = nullptr; |
| 358 | std::shared_ptr<const Vevo2VocoderWeights> weights; |
| 359 | int64_t frames = 0; |
| 360 | int64_t input_channels = 0; |
| 361 | int64_t head_dim = 0; |
| 362 | std::unique_ptr<ggml_context, GgmlContextDeleter> ctx; |
| 363 | ggml_tensor * input = nullptr; |
| 364 | ggml_tensor * output = nullptr; |
| 365 | ggml_cgraph * graph = nullptr; |
| 366 | ggml_gallocr_t gallocr = nullptr; |
| 367 | }; |
| 368 | |
| 369 | Vevo2VocoderRuntime::Vevo2VocoderRuntime( |
| 370 | const Vevo2Assets & assets, |
| 371 | engine::core::ExecutionContext & execution_context, |
| 372 | size_t weight_context_bytes, |
| 373 | size_t graph_context_bytes, |
| 374 | engine::assets::TensorStorageType matmul_weight_storage_type, |
| 375 | engine::assets::TensorStorageType conv_weight_storage_type) |
| 376 | : config_(assets.config.vocoder), |
| 377 | execution_context_(execution_context), |
| 378 | graph_context_bytes_(graph_context_bytes), |
| 379 | weight_source_(assets.vocoder_weights_0), |
| 380 | weights_(load_vocoder_weights( |
| 381 | execution_context.backend(), |
| 382 | execution_context.backend_type(), |
no test coverage detected