{"id":22472585,"url":"https://github.com/jcarrano/rtfi","last_synced_at":"2025-07-06T12:07:01.323Z","repository":{"id":8012058,"uuid":"9420494","full_name":"jcarrano/rtfi","owner":"jcarrano","description":"Audio visualization \u0026 analysis using the RTFI","archived":false,"fork":false,"pushed_at":"2020-11-05T16:21:56.000Z","size":183,"stargazers_count":11,"open_issues_count":1,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-04-08T17:52:45.379Z","etag":null,"topics":["audio-processing","audio-visualizer","c","filterbank","jack-audio-connection-kit","signal-processing","spectrogram","time-frequency"],"latest_commit_sha":null,"homepage":null,"language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/jcarrano.png","metadata":{"files":{"readme":"README.rst","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2013-04-13T21:34:57.000Z","updated_at":"2024-07-17T08:47:37.000Z","dependencies_parsed_at":"2022-09-05T21:02:06.321Z","dependency_job_id":null,"html_url":"https://github.com/jcarrano/rtfi","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/jcarrano/rtfi","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcarrano%2Frtfi","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcarrano%2Frtfi/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcarrano%2Frtfi/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcarrano%2Frtfi/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/jcarrano","download_url":"https://codeload.github.com/jcarrano/rtfi/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/jcarrano%2Frtfi/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":263897981,"owners_count":23526832,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["audio-processing","audio-visualizer","c","filterbank","jack-audio-connection-kit","signal-processing","spectrogram","time-frequency"],"created_at":"2024-12-06T12:16:28.370Z","updated_at":"2025-07-06T12:07:01.304Z","avatar_url":"https://github.com/jcarrano.png","language":"C","readme":"==============================\nResonator Time-Frequency Image\n==============================\n\n-----------------\nby Juan I Carrano\n-----------------\n\n.. pull-quote::\n   Here, watch a video_ of it in action!\n\nIntroduction\n============\n\nThis is an implementation of the RTFI, as described in [Zhou]_. It consists of a\nbank of band-pass filters, whith the same Q-factors and exponentially spaced\ncenter frequencies. The filter are single complex pole resonators, that is they\nare not symmetric in the Z-plane. They take a real input, but have a complex\nstate and a complex output. The advantage of this is that the envelope of the\nfiltered signal can be obtained by calculating the norm of the output samples.\nIn order to make the calculation of 900 filters feasible in real time, the\nmultirate approach suggested by Zhou is employed.\n\nHistory\n-------\n\n0.0.3 (Jun '19)\n  - Add Makefile\n  - Fix compilation issues with C99\n  - Reorganize repo\n\n0.0.2 (Nov '18)\n  Revive project. Assign version number and refomat README.\n\nMarch '13\n  Repackaged to include extra_libraries.\n\nMid 2012\n  Initial version. Derived from a course project in Signals and Systems (the\n  original code was MATLAB and was not real time.\n\nUsage\n=====\n\nThe only supported sample frequencies are 44100Hz, 48000Hz and 96000Hz. This is\nbecause filter coefficients are only calculated for those frequencies.\n\nTo start the program::\n\n  # (if necessary) Launch the jack daemon\n  $ jackd -r -d alsa\n  # Launch rtfi:\n  $ ./rtfi [width] [height]\n  # or go fullscrenn with\n  $ ./rtfi f\n\nWithin the program you can use the following key controls:\n\nESC, q\n  exit\nUP, DOWN\n  move y axes. Holding SHIFT moves by a greater amount\nLEFT, RIGHT\n  change between ARTFI, AES, PES; SPES and NPES\n\nBuilding\n========\n\nRequirements\n------------\n\njack-audio-connection-kit_\n\n\nCompilation\n-----------\n\ntype::\n\n  $ make\n\nTo rebuild the autogenerated files use::\n\n  $ make generated\n\nTo clean use ``make clean``. To wipe everything use ``make wipe``.\n\nImplementation details\n======================\n\nThis code uses the jack-audio-connection-kit and SDL. The filter bank runs as a\nJACK callback, and outputs a ARTFI frame (consisting of 900 bins) every 10ms to\na circular buffer capable of holding 6 frames. The drawing thread reads from\nthis buffer. Synchronization is done by semaphores, where the value of the\nsemaphore represents the number of frames waiting to be read. The drawing\nthread processes the ARTFI data to obtain AES, PES, SPES and NPES. Finally,\nthere is a UI thread processes keyboard events.\n\nThe script ``rtfi.py`` calculates the coefficients and generates the C-files\ncontaining the tables.\n\nCurrent limitations \u0026 issues\n============================\n\nThe multirate processing does not take into account the delays introduced by\ndecimating filters. Because of this, the lower-frequency bins of the ARTFI are\ndelayed with respect to the higher frequency ones. This degrades the note\ndetection capabilities for fast and short notes. Low frequency content and\npercussion also affects the note detection ability. Equalizing the signal\nbefore feeding it to the RTFI can alleviate the problem. This can be done\neasily with jack-rack or similar software.\n\n.. [Zhou] R. Zhou and M. Mattavelli, \"A new time-frequency representation for\n   music signal analysis: resonator time-frequency image,\" in Proceedings of the\n   9th International Symposium on Signal Processing and Its Applications\n   (ISSPA '07), Sharijah, UAE, February 2007.\n\n.. _jack-audio-connection-kit: http://jackaudio.org/\n\n.. _SDL: http://www.libsdl.org/\n\n.. _video: https://youtu.be/xMLPreq_8Bo\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjcarrano%2Frtfi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fjcarrano%2Frtfi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fjcarrano%2Frtfi/lists"}