pyFDN.build_to_flamo#
- pyFDN.build_to_flamo(build, nfft=65536, device=None, *, shell=True, dtype=None, post_delay_module=None)[source]#
Build a FLAMO model from a complete
FDNBuildconfig.Thin wrapper over
dss_to_flamo()that unpacks anFDNBuild(as returned bypyFDN.fdn_build_gallery()) into its state-space arguments, mapping the in-loop absorptionbuild.filterstosos_filterand the per-outputbuild.post_eqtooutput_filter.- Parameters:
build (FDNBuild) – Complete FDN parameters (
A,B,C,D,delays,fs, optionalfiltersandpost_eq), e.g. frompyFDN.fdn_build_gallery().nfft (int) – FFT size for FLAMO (default 2**16).
device (torch device or None) – Device; default is cuda if available else cpu.
shell (bool) – If True (default), wrap the core in a Shell with FFT/iFFT. Use
pyFDN.flamo_time_response()to obtain a NumPy impulse response. If False, return only the core.dtype (torch.dtype or None) – Optional dtype for FLAMO delay/gain/filter modules (e.g., torch.float64). If None, wrapper defaults are used.
post_delay_module (FLAMO module or None) – Optional module to append after the delay in the recursion (e.g. a Schroeder allpass core). Must have input/output size N. Loop becomes: delay -> post_delay_module -> A.
- Returns:
model – If shell=True, a FLAMO Shell. Use
pyFDN.flamo_time_response()for a NumPy impulse response. If shell=False, the core module.- Return type:
flamo.processor.system.Shell or core