pulsatrix
Loading...
Searching...
No Matches
wav_reader.hpp
Go to the documentation of this file.
1
5#pragma once
6
7#include <string>
8
10#include "pulsatrix/tensor.hpp"
11
12namespace pulsatrix {
13
20
31class WavReader {
32public:
41 [[nodiscard]] static WavData Load(const std::string& path, DeviceBackend* backend);
42};
43
44} // namespace pulsatrix
Vendor-agnostic compute/memory backend. CPUBackend, CUDABackend (Phase 1.5), and HIPBackend (Phase 1....
Definition device_backend.hpp:219
N-dimensional tensor. Owns its data buffer exclusively; a DeviceBackend* is injected (not owned) – th...
Definition tensor.hpp:29
Reads uncompressed 16-bit PCM WAV files directly – pulsatrix's first audio primitive (campaign_exai_d...
Definition wav_reader.hpp:31
static WavData Load(const std::string &path, DeviceBackend *backend)
Abstract interface isolating vendor-specific memory/compute operations from Tensor/ComputationGraph.
Definition acquisition_functions.hpp:16
One decoded WAV file's contents: waveform Tensor plus its sample rate.
Definition wav_reader.hpp:15
int sample_rate
Definition wav_reader.hpp:18
Tensor waveform
Shape (1, channels, num_samples), float32, normalized to [-1,1].
Definition wav_reader.hpp:17
N-dimensional tensor – owns a buffer via DeviceBackend*, RAII (Rule of Five).