| 740 | threads_(std::max(1, execution.config().threads)), |
| 741 | graph_arena_bytes_(graph_arena_bytes), |
| 742 | weights_(std::make_shared<VAEDecoderWeights>( |
| 743 | load_vae_decoder_weights(*assets_, backend_, backend_type_, weight_context_bytes, weight_storage_type))) { |
| 744 | if (assets_ == nullptr) { |
| 745 | throw std::runtime_error("ACE-Step VAE runtime requires assets"); |
| 746 | } |
| 747 | if (backend_ == nullptr) { |
| 748 | throw std::runtime_error("ACE-Step VAE backend is not initialized"); |
| 749 | } |
| 750 | assets_->vae_weights->release_storage(); |
| 751 | } |
| 752 | |
| 753 | static int64_t decode_direct_frame_limit(core::BackendType backend_type) noexcept { |
| 754 | return core::uses_host_graph_plan(backend_type) ? 256 : 512; |
| 755 | } |
| 756 | |
| 757 | static int64_t decode_tiled_chunk_frames(core::BackendType backend_type) noexcept { |
| 758 | return core::uses_host_graph_plan(backend_type) ? 256 : 128; |
| 759 | } |
| 760 | |
| 761 | static int64_t requested_decode_overlap_frames() noexcept { |
| 762 | return 64; |
| 763 | } |
| 764 | |
| 765 | static int64_t effective_decode_overlap(int64_t chunk_frames, int64_t requested_overlap) noexcept { |
nothing calls this directly
no test coverage detected