Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

KFR Roadmap #196

Closed
dancazarin opened this issue Oct 13, 2023 · 7 comments
Closed

KFR Roadmap #196

dancazarin opened this issue Oct 13, 2023 · 7 comments
Labels
Milestone

Comments

@dancazarin
Copy link
Member

KFR Roadmap

🎯 KFR 6

Matrix transpose

Both inplace and out-of-place options will be supported as well as other matrix operations.

2D DFT #127 #81

Also DFT-based algorithms such as DCT will get 2D variants too.

Applying a function along axis of tensor<>

With full vectorization support.

More functions to support $N$-dim tensor<>

Separate state_holder for all DSP algorithms #78

With this change it will be possible to prefill state before performing actual filtering. No more need to keep constructed expressions just to keep the state itself.

More audio formats #126

  • Fuller support for WAV variants (BW64, RF64)
  • FLAC using libFLAC
  • MP3
  • AIFF
  • ALAC, Apple Lossless Audio Codec
  • 32/64-float data support, Little/Big Endian
  • Metadata support.
  • Optimized format conversion.

🚀 Future versions

Elliptic filters #163

To extend the list of already supported Butterworth, Bessel and Chebyshev I/II filters.

RISC-V support

.npy format support

To be able to load and store KFR tensors to and from numpy's .npy format.

Prebuilt binaries using GitHub Actions

Built in Clang compiler (known to provide the best performance for heavy-vectorized code) but usable for both GCC and MSVC.

GCC and MSVC support for DFT #70

Capture subexpressions by value unless std::ref or std::cref is used

This will fix potential errors with temporary scalars and subexpressions captured by references.

This is a breaking change.

Multithreading #63

Multithread DFT and other algorithms.

@dancazarin dancazarin added this to the KFR 6 milestone Oct 13, 2023
@meiyasan
Copy link

meiyasan commented Oct 26, 2023

All of this would be fantastic features. Thank you for bringing a light over the remaining work.
Especially about multithreaded DFT, 2D DFT, and elliptic filter.

Do you have any idea already about the timeline of this roadmap ?
Is it about several months of work or a year maybe ?

@dancazarin
Copy link
Member Author

KFR 6 is scheduled for the coming weeks with 2D DFT, improved DFT performance (up to 30-50% increase in speed depending on architecture and DFT size) and all other features listed here under KFR 6 section. Future versions section is what will be implemented in one of the next releases of KFR but after KFR 6. There is no exact schedule of these features yet and the priority depends on many factors (commercial requests etc).

@meiyasan
Copy link

Sounds amazing, I definitely need to try this :-)

@meiyasan
Copy link

meiyasan commented Nov 24, 2023

@dancazarin Is there any plan to implement short time fourier transform and reverse ?
It would be great to have such features. What do you think, were there some discussions about it already ?

@dancazarin
Copy link
Member Author

KFR 5.2.0 has been released with DFT performance improvements and all latest fixes. KFR 6 is on the way.

As for STFT, it's basically a combination of DFT and window function, both are implemented in KFR. It's possible to make a class that encapsulates these operations and also performs splitting streamed data to chunks etc. Is it what you think about? Right now KFR focuses on algorithms that process data in memory buffers, not streams but it may be considered for future releases. Or your data is available all at once?

@meiyasan
Copy link

Hi @dancazarin Thank you for the update !
My use case is twice. I can run offline analysis where I have all at once data, or online data that are a stream of data.(basically, one set per second.)

@dancazarin
Copy link
Member Author

KFR6 preview has been released. Pull new changes from GitHub and switch to v6 branch to test new features.
Multiarchitecture mode is now enabled by default and controlled by CMake flag KFR_ENABLE_MULTIARCH.
Besides DFT the multiarchitecture mode now includes resampling, FIR filters, IIR filters and more.
There is a possibility to override cpu detected at runtime.

In addition to 1D DFT a Multidimensional DFT (both complex and real) is available through dft_plan_md and dft_plan_md_real classes. The number of dimensions can be a runtime constant (use dynamic_shape as NDims value).

kfr::complex has been removed in favor of using std::complex everywhere. Graphics module is also removed in KFR6.

CMake config generation during install makes KFR usage as simple as adding find_package(KFR CONFIG REQUIRED) to CMakeLists.txt.

DFT and DSP source code moved to /src. simd, math, base modules are still header-only.

(Experimental) With KFR_WITH_CLANG CMake flag enabled it transparently downloads official build of latest Clang and configures cmake compilation to use clang instead of default compiler for Linux and Windows.

C API is supported in both Intel and ARM and supports error handling.

Accelerated matrix transposition with any number of dimensions.

Numerous small enhancements and bug fixes.

Examples, documentation and migration guide will be added later.

More features are ready to be released.

Expect force-pushes and API changes in v6 branch. For production code it's reasonable to wait for the official KFR6 release.

KFR5 will be supported in bug-fix mode until the next major release of KFR.

@kfrlib kfrlib locked and limited conversation to collaborators Feb 2, 2024
@dancazarin dancazarin converted this issue into discussion #216 Feb 2, 2024
@dancazarin dancazarin unpinned this issue Feb 5, 2024

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
Projects
None yet
Development

No branches or pull requests

2 participants