| 48 | for (int64_t i = 0; i < static_cast<int64_t>(out.samples.size()); ++i) { |
| 49 | out.samples[static_cast<size_t>(i)] -= vocals.samples[static_cast<size_t>(i)]; |
| 50 | } |
| 51 | return out; |
| 52 | } |
| 53 | |
| 54 | std::shared_ptr<const RoformerAssets> require_assets(std::shared_ptr<const RoformerAssets> assets) { |
| 55 | if (assets == nullptr) { |
| 56 | throw std::runtime_error("RoFormer session requires assets"); |
| 57 | } |
| 58 | return assets; |
| 59 | } |
| 60 | |
| 61 | std::shared_ptr<const engine::model_spec::ModelContract> require_contract( |
| 62 | std::shared_ptr<const engine::model_spec::ModelContract> contract) { |
| 63 | if (contract == nullptr) { |
nothing calls this directly
no test coverage detected