Closed
Conversation
* Add profiling instrumentation for NAM building blocks Adds a profiling framework (NAM/profiling.h, NAM/profiling.cpp) with NAM_PROFILE_START()/NAM_PROFILE_ADD() macros and 14 timing categories. Supports both desktop (std::chrono) and ARM Cortex-M7 (DWT cycle counter) backends. Profiling is compile-time gated via -DNAM_PROFILING. Instruments wavenet _Layer::Process() and _LayerArray::ProcessInner() with per-category timing, and adds profiling reset/print calls to the benchmodel tool. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * Fixed build flags for benchmodel * Added a command line tool to output memory usage for a given .nam file * Bugfix - checking that condition_dsp is not null in the JSON (#220) * [BUGFIX, BREAKING] Make activation base class abstract, fix PReLU implementation (#223) * Make activation apply method pure virtual instead of no-op default * Fix bugs * Refactor to throw std::invalid_argument in debug mode, add tests * Add TONE3000 support note in README.md (#224) * Replace hardcoded profiling struct with dynamic registry The Timings struct hardcoded 14 named fields, requiring manual updates to reset(), total(), print_results(), and every call site whenever a category was added or removed. Replace with a flat-array registry where types are registered at file scope via register_type(), returning an integer index for O(1) accumulation in the hot path. Also adds NAM_PROFILE_RESTART() macro to replace a raw #ifdef block in wavenet.cpp. --------- Co-authored-by: João Felipe Santos <santosjf@pm.me> Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com> Co-authored-by: Steven Atkinson <steven@atkinson.mn>
- Add AudioDSPTools as submodule for WAV input (dsp::wav::Load) - Add tools/render: loads model, reads input WAV, processes, writes 32-bit float output - Usage: render <model.nam> <input.wav> [output.wav] - Supports mono input; validates sample rate matches model Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
use:
./build/tools/render model.nam input.wav output.wavRequired for Atkinson-Advanced-Modeling/NamIntegrationTests#1