Skip to content

Commit

Permalink
[Release] 1.0.0 (#158)
Browse files Browse the repository at this point in the history
* mfcc rst and sc help file

* mfcc sc examples

* mfcc output

* mfcc helpfile readability

* BufMFCC udpates

* update bufonsetslice docs slightly (#87)

* fix audio transport segmentation of discussion and desc

* fix audio transport segmentation of discussion and desc (#88)

* add missing see alsos

* optional args: add to C++ wrapper

* ParamDump and python: add choices param type

* Json driver (#35)

* Make jinja rendering conditional on driver having a template

* minimal driver for raw JSON output

* cmake target for raw JSON

* fix cmake output directory

* add command line option for raw

* remove spurious item from raw driver

* add back changes that dealt with conditional template rendering

* add a github action for creating a basic API on actions

Co-authored-by: James Bradbury <[email protected]>

* Update json_api.yml

* Update json_api.yml

* Update json_api.yml

* change name of raw output to api.json

* Update json_api.yml

* remove indentation on api

* typo in UMAP

* [Docs] OnsetSlice and BufOnsetSlice (#91)

* update bufonsetslice text

* onsetslice update

* ted's changes

* copy changes to bufonsetslice also

* revamp MelBands and BufMelBands RST, update SC example code

* *melbands description

* added a hyphen

* pitch and buf pitch RST

* added link to the learn page

* edited normalize description

* pitch sc help files

* BufFlatten RST and SC examples

* buf thresh

* sc help file

* typo in fluid pitch sc example code

* bufthresh rst

* typo

* james' feedback

* add .ds_store to gitignore

* pa feedback

* pa feedback

* pa feedback

* PA feedback

* [Docs] Update Normalize Docs (#76)

* update normalize entry

* update description

* pa's requests

Co-authored-by: James Bradbury <[email protected]>

* [Docs] Slicer Feature Objects (#101)

* add skeleton of bufnoveltyfeature

* caveat novelty feature

* add onset feature

* remove space

* add bufampfeature

* realtime amp feature

* update output of AmpFeature

* clean up the language

* caveats for bufonset feature

* add onset feature

* Add JSON generators for Slicers' feature counterparts

* rt noveltyfeature

* fix various errors

* robots in disguise

* change feature -> algorithm

* cleanup noveltyfeature

* make noveltyfeature more consistent

* remove superfluous spaces

* fix description

* fix reference to buffer version in rt object

* add padding

* sc example code for slicer-features

Co-authored-by: weefuzzy <[email protected]>
Co-authored-by: Ted Moore <[email protected]>

* changing preset and interface for noveltyslice examples

* Add argument handlers for const DataSet / LabelSet

* Max/PD: Generate docs for control-in objects (input size and autosize)

* Enhance/max params (#104)

* CMake: Centralise C++ version and set to 17

* Wrapper: Handle new LongRuntimeMax parameter type

* Doc generators: Handle new LongRuntimeMax type + rules for args in Max/PD

* Add a `striprst` jinja filter for removing rst markup in templates (#107)

Such as Max object level description tags

* UMAP cmake reference to python sorted

* typo

* Wrapper and doc-gen update for new `maxFFTSize`

* Buf stats (#103)

* BufStats RST

* BufStats ⚠️

* bufstats supercollider examples

* re-organized descriptions

* added table back in

* typo

* added url

* bufcompose update (#95)

* PCA inverseTransformPoint (#97)

* PCA inverseTransformPoint

* added inverseTransform to PCA RST

* off by one white space 😠

* normalize the desc/disc of mfcc entries (#113)

* HPSS Help file (RST) and SC examples (#81)

* HPSS rst edited and SC examples created

* pa feedback

* Enhance/generate stubs (#119)

* CMake: Generate cpp stubs, smooth out API for dependent projects

* Remove old stubs and scripts

* CMake: Ensure correct MSVC runtime by default

* Correct variable setting logic in macro

* CI: Debug CMAKE_MODULE_PATH

* CMake: Try setting module path using explicit source dir for core

* CI Debug: Print core/scripts

* CMake: Correct typo

* CMake: MSVC with bigobj, tidy up messages

* set explicit UTF8 encoding when opening text

* explicitly use utf8 for writing as well as reading

* MDS RST & SC example code (#121)

* MLPClassifier SC example code

* MLPClassifier SC example code ⚠️

* MLPs SC example code and RSTs ⚠️

* ⚠️

* ⚠️

* wip

* MLP RSTs

* [FIX] this commit adds code to the SC templates to allow enums in the RST to appear in the species data

* feedback

* hidden -> hiddenLayers

* ⚠️

* sc example ⚠️

* sc example code

* bump

* typo

* removed cosine

* weefuzzy and james feedback

* fixed plot size

* MLPRegressor & MLPClassifier RSTs & SC example Code (#109)

* MLPClassifier SC example code

* MLPClassifier SC example code ⚠️

* MLPs SC example code and RSTs ⚠️

* ⚠️

* ⚠️

* wip

* MLP RSTs

* [FIX] this commit adds code to the SC templates to allow enums in the RST to appear in the species data

* feedback

* hidden -> hiddenLayers

* Standardize RST & SC examples (#117)

* Standardize RST & SC example code

* removed the 'invert' argument

* added discussion

* RobustScale (#118)

* ⚠️

* RobustScale RST

* RobustScale SC example code

* bump

* added discussion

* KNNClassifier RST and SC example code (#127)

* KNN ⚠️

* reset knnregressor.rst

* Stats RST & SC examples (#124)

* Stats RST and SC code

* stats rst and sc code

* feedback

* PCA RST and SC Examples (#116)

* PCA RST

* PCA SC example code

* sc example code with whitening example

* added discussion

* james' feedback

Co-authored-by: James Bradbury <[email protected]>

* Update Standardize.rst

Fix indentation error that caused mis-parsing

* maxFFTSize in SC driver is conditional on buffer-proc species (#129)

* BufSTFT RST and SC example code (#112)

* BufSTFT RST and SC example code

* added discussion

* typo

* [Enhance] Learn platform link generation (#120)

* update default transformer to handle learn links

* update maxref template to acount for learn link

* add link to templates discussion

* compartmentalise the learn link derivation

* update the supercollider driver which doesnt use default transform

* use a regex instead of object map

* update derivation of learn links

* add test for link derivation

* typo

* bufnmf: adding resynthmode

* resynthMode : camel case

* Change size to history (#133)

* BufNMFCross RST & SC example (#137)

* NNDSVD (#138)

* ⚠️

* BufNNDSVD RST & SC examples

* NNDSVD RST with descriptions of method

* add token for |buffer|

* feedback

Co-authored-by: James Bradbury <[email protected]>

* NMFMorph (& species transformer[0]) (#135)

* NMFMorph RST and SC examples

* NMFMorph

* NMFMorph (and species transformer[0])

* separate discussion and description

* added comment about why autoassign is set twice

Co-authored-by: James Bradbury <[email protected]>

* put bar chart back in (#123)

* KNNRegressor (#136)

* KNNRegressor RST & SC examples

* fixed sc code formatting

* separate discussion and description!

* (Buf)Transients(Slice) Family (#140)

* transients RST

* ⚠️

* ⚠️

* more sc examples for transients family

* feedback from owen and alex

* feedback round 1

* feedback

* typos in rst

* typos in knnclassifier~ (#142)

* sc example code for BufNMF now includes resynthMode

* deleted SC Guid YAML file

* put spaces around hyperlinks

* BufTransients SC example (Waveform only 2 sec.)

* BufNNDSVD -> BufNMFSeed (#141)

* change the doc

* forgot to change the code sample file name

* fix Loudness select in MLPRegressor example code

* fix bad link in nmf morph (BufNMFCross was missing the buf part)

* added inverse transform and inverse transform point to Normalize

* better code for testing all flucoma objects help files

* added argument k to KDTree RST

* fixed a bad link in KNNClassifier RST

* removed action arguments from RobustScale RST

* fixed mistakes in RobustScale RST that was causing it to not render properly

* added select argument to BufLoudness and Loudness RST (the rest coming soon...)

* added pca whitening to PCA RST

* adding select argument to appropriate RST files

it would be nicer to have them in list form... TODO

* added radius argument to KDTree RST

* added channels argument to BufSelect RST

* checked example code files that use 'select' for possible errors

* found a bit more code needing resynthMode

* [Enhance] Interp to Interplation in NMFMorph (#143)

* typos in knnclassifier~

* change interp to interpolation for nmfmorph

* SKMeans (#132)

* skmeans doc commit

* skmeans: attempt at better doc

* example code a little more explicit

* typos found in kmeans

* update from @weefuzzy feedback - less untrue in most cases :)

* <fit>transform<point> -> <fit>encode<point>

* (Buf)AmpGate RST & SC examples (#122)

* (Buf)AmpGate RST & SC examples

* BufAmpGate help file ⚠️

* drum hit example ⚠️

* ⚠️

* gitignore to ignore vs code

* pa feedback

* added BufAmpGate maxSize parameter

* [Fix] Fix Guide Links in RST (#147)

* typos in knnclassifier~

* fix guide link

* [Fix] LF line ending enforcement (#149)

* typos in knnclassifier~

* enforce newline='\n' on template writing

* interface changes

* capitalise beatRemember

* Fix `<o>` links to `buffer~` for max doc

* Mop up vestigial scdoc syntax

* correct reference to "class" in description

* [fix] typos and errors (#153)

* various typos

* remove hyphen

* more typos

* various typos/non-grammatical errors

* typos in example code

* remove bufNum

* fix low/mid/ min/median confusion

* [docs] Update see-also content (#155)

* update seealso

* realign table

* [docs] Buffer clients link to buffer management tutorial (#157)

* if client starts with buf link to buffer management tutorial

* use full name of guide

* use name of .maxvig rather than name attribute of <vignette>

* also dataset objects

* proposed layout improvement (#154)

* add outward links to RST and templat
  • Loading branch information
jamesb93 authored Jun 24, 2022
1 parent 0c86d59 commit dc45022
Show file tree
Hide file tree
Showing 81 changed files with 441 additions and 255 deletions.
1 change: 1 addition & 0 deletions doc/AmpFeature.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: AmpGate, AmpSlice, OnsetFeature, NoveltyFeature
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Calculate the amplitude differential feature in realtime.
:discussion:
:fluid-obj:`AmpSlice` uses the differential between a fast and a slow envelope follower to determine changes in amplitude. This object calculates the amplitude differential and copies it to an output buffer.
Expand Down
3 changes: 2 additions & 1 deletion doc/AmpGate.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: BufAmpGate, AmpSlice, OnsetSlice, NoveltySlice, TransientSlice
:description: Absolute amplitude threshold gate detector on a real-time signal
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Absolute amplitude threshold gate detector on a realtime signal

:discussion:
AmpGate outputs a audio-rate, single-channel signal that is either 0, indicating the gate is closed, or 1, indicating the gate is open. The gate detects an onset (opens) when the internal envelope follower (controlled by ``rampUp`` and ``rampDown``) goes above a specified ``onThreshold`` (in dB) for at least ``minLengthAbove`` samples. The gate will stay open until the envelope follower goes below ``offThreshold`` (in dB) for at least ``minLengthBelow`` samples, which triggers an offset.
Expand Down
9 changes: 5 additions & 4 deletions doc/AmpSlice.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: BufAmpSlice, AmpGate, OnsetSlice, NoveltySlice, TransientSlice
:description: This class implements an amplitude-based slicer, with various customisable options and conditions to detect relative amplitude changes as onsets.
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Implements an amplitude-based slicer, with various customisable options and conditions to detect relative amplitude changes as onsets.
:discussion:
FluidAmpSlice is based on two envelop followers on a highpassed version of the signal: one slow that gives the trend, and one fast. Each have features that will interact. The example code below is unfolding the various possibilites in order of complexity.
FluidAmpSlice is based on two envelope followers on a high-passed version of the signal: one slow that gives the trend, and one fast. Each has features that will interact. The example code below is unfolding the various possibilities in order of complexity.

The process will return an audio steam with single sample impulses at estimated starting points of the different slices.
The process will return an audio stream with single sample impulses at estimated starting points of the different slices.

:output: An audio stream with square envelopes around the slices. The latency between the input and the output is **max(minLengthAbove + lookBack, max(minLengthBelow,lookAhead))**.

Expand All @@ -34,7 +35,7 @@

:control offThreshold:

The threshold in dB of the relative envelope follower to reset, aka to allow the differential envelop to trigger again.
The threshold in dB of the relative envelope follower to reset, aka to allow the differential envelope to trigger again.

:control floor:

Expand Down
2 changes: 1 addition & 1 deletion doc/AudioTransport.rst
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@

:discussion:
Interpolates between the spectra of two sounds using the optimal transport algorithm. This enables morphing and hybridisation of the perceptual qualities of each source linearly.
See Henderson and Solomonm (2019) AUDIO TRANSPORT: A GENERALIZED PORTAMENTO VIA OPTIMAL TRANSPORT, DaFx
See Henderson and Solomon (2019) AUDIO TRANSPORT: A GENERALIZED PORTAMENTO VIA OPTIMAL TRANSPORT, DaFx

https://arxiv.org/abs/1906.06763

Expand Down
16 changes: 14 additions & 2 deletions doc/BufAmpFeature.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: BufAmpSlice, BufNoveltyFeature, BufAmpFeature, BufOnsetFeature
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Calculate the amplitude differential feature used by :fluid-obj:`BufAmpSlice`.
:discussion:
:fluid-obj:`BufAmpSlice` uses the differential between a fast and a slow envelope follower to determine changes in amplitude. This object calculates the amplitude differential and copies it to an output buffer.
Expand All @@ -28,7 +29,7 @@

:control numChans:

For multichannel sources, how many channel should be summed.
For multichannel sources, how many channels should be summed.

:control features:

Expand Down Expand Up @@ -60,7 +61,18 @@

:control padding:

Controls the zero-padding added to either end of the source buffer or segment. Possible values are 0 (no padding), 1 (default, half the window size), or 2 (window size - hop size). Padding ensures that all input samples are completely analysed: with no padding, the first analysis window starts at time 0, and the samples at either end will be tapered by the STFT windowing function. Mode 1 has the effect of centering the first sample in the analysis window and ensuring that the very start and end of the segment are accounted for in the analysis. Mode 2 can be useful when the overlap factor (window size / hop size) is greater than 2, to ensure that the input samples at either end of the segment are covered by the same number of analysis frames as the rest of the analysed material.
Controls the zero-padding added to either end of the source buffer or segment. Padding ensures all values are analysed. Possible values are:

:enum:

:0:
No padding - The first analysis window starts at time 0, and the samples at either end will be tapered by the STFT windowing function.

:1:
Half the window size - The first sample is centred in the analysis window ensuring that the start and end of the segment are accounted for in the analysis.

:2:
Window size minus the hop size - Mode 2 can be useful when the overlap factor (window size / hop size) is greater than 2, to ensure that the input samples at either end of the segment are covered by the same number of analysis frames as the rest of the analysed material.

:control action:

Expand Down
5 changes: 3 additions & 2 deletions doc/BufAmpGate.rst
Original file line number Diff line number Diff line change
@@ -1,8 +1,9 @@
:digest: Gate Detection on a Bfufer
:digest: Gate Detection on a Buffer
:species: buffer-proc
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: AmpGate, BufAmpSlice, BufOnsetSlice, BufNoveltySlice, BufTransientSlice
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Absolute amplitude threshold gate detector on audio in a buffer

:discussion:
Expand Down Expand Up @@ -79,7 +80,7 @@

:control highPassFreq:

The frequency of the fourth-order Linkwitz-Riley high-pass filter (https://en.wikipedia.org/wiki/Linkwitz%E2%80%93Riley_filter) applied to the signal signal to minimise low frequency intermodulation with very short ramp lengths. A frequency of 0 bypasses the filter.
The frequency of the fourth-order Linkwitz-Riley high-pass filter (https://en.wikipedia.org/wiki/Linkwitz%E2%80%93Riley_filter) applied to the signal to minimise low frequency intermodulation with very short ramp lengths. A frequency of 0 bypasses the filter.

:control maxSize:

Expand Down
9 changes: 5 additions & 4 deletions doc/BufAmpSlice.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,10 @@
:sc-categories: Libraries>FluidDecomposition
:sc-related: Guides/FluidCorpusManipulation
:see-also: AmpSlice, BufAmpGate, BufOnsetSlice, BufNoveltySlice, BufTransientSlice
:description: This class implements an amplitude-based slicer,with various customisable options and conditions to detect relative amplitude changes as onsets.
:max-seealso: peakamp~, meter~, snapshot~, slide~
:description: Implements an amplitude-based slicer, with various customisable options and conditions to detect relative amplitude changes as onsets.
:discussion:
FluidBufAmpSlice is based on two envelop followers on a highpassed version of the signal: one slow that gives the trend, and one fast. Each have features that will interact. The example code below is unfolding the various possibilites in order of complexity.
FluidBufAmpSlice is based on two envelope followers on a high-passed version of the signal: one slow that gives the trend, and one fast. Each has features that will interact. The example code below is unfolding the various possibilities in order of complexity.

The process will return a buffer which contains indices (in sample) of estimated starting points of different slices.

Expand All @@ -30,7 +31,7 @@

:control numChans:

For multichannel sources, how many channel should be summed.
For multichannel sources, how many channels should be summed.

:control indices:

Expand Down Expand Up @@ -58,7 +59,7 @@

:control offThreshold:

The threshold in dB of the relative envelope follower to reset, aka to allow the differential envelop to trigger again.
The threshold in dB of the relative envelope follower to reset, aka to allow the differential envelope to trigger again.

:control floor:

Expand Down
2 changes: 1 addition & 1 deletion doc/BufAudioTransport.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
:discussion:
Interpolates between the spectra of two sounds using the optimal transport algorithm. This enables morphing and hybridisation of the perceptual qualities of each source linearly.

See Henderson and Solomonm (2019) AUDIO TRANSPORT: A GENERALIZED PORTAMENTO VIA OPTIMAL TRANSPORT, DaFx
See Henderson and Solomon (2019) AUDIO TRANSPORT: A GENERALIZED PORTAMENTO VIA OPTIMAL TRANSPORT, DaFx

https://arxiv.org/abs/1906.06763

Expand Down
17 changes: 14 additions & 3 deletions doc/BufChroma.rst
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

:control source:

The index of the buffer to use as the source material to be analysed. The different channels of multichannel buffers will be processing sequentially.
The index of the buffer to use as the source material to be analysed. The different channels of multichannel buffers will be processed sequentially.

:control startFrame:

Expand All @@ -31,7 +31,7 @@

:control numChans:

For multichannel srcBuf, how many channel should be processed.
For multichannel srcBuf, how many channels should be processed.

:control features:

Expand Down Expand Up @@ -71,7 +71,18 @@

:control padding:

Controls the zero-padding added to either end of the source buffer or segment. Possible values are 0 (no padding), 1 (default, half the window size), or 2 (window size - hop size). Padding ensures that all input samples are completely analysed: with no padding, the first analysis window starts at time 0, and the samples at either end will be tapered by the STFT windowing function. Mode 1 has the effect of centering the first sample in the analysis window and ensuring that the very start and end of the segment are accounted for in the analysis. Mode 2 can be useful when the overlap factor (window size / hop size) is greater than 2, to ensure that the input samples at either end of the segment are covered by the same number of analysis frames as the rest of the analysed material.
Controls the zero-padding added to either end of the source buffer or segment. Padding ensures all values are analysed. Possible values are:

:enum:

:0:
No padding - The first analysis window starts at time 0, and the samples at either end will be tapered by the STFT windowing function.

:1:
Half the window size - The first sample is centred in the analysis window ensuring that the start and end of the segment are accounted for in the analysis.

:2:
Window size minus the hop size - Mode 2 can be useful when the overlap factor (window size / hop size) is greater than 2, to ensure that the input samples at either end of the segment are covered by the same number of analysis frames as the rest of the analysed material.

:control maxFFTSize:

Expand Down
13 changes: 7 additions & 6 deletions doc/BufCompose.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,12 @@
:sc-categories: Libraries>FluidDecomposition, UGens>Buffer
:sc-related: Guides/FluidCorpusManipulation, Classes/Buffer
:see-also: BufSelect, BufSelectEvery
:max-seealso: poke~, peek~, index~, buffer~
:description:
A utility for manipulating the contents of buffers.

:discussion:
This object is the swiss army knife for manipulating buffers and their contents. By specifing ranges of samples and channels to copy, as well as destination and source gains it can provide a powerful interface for performing actions such as a Left/Right to Mid/Side conversion and mixing down multichannel audio
This object is the swiss army knife for manipulating buffers and their contents. By specifying ranges of samples and channels to copy, as well as destination and source gains it can provide a powerful interface for performing actions such as a Left/Right to Mid/Side conversion and mixing down multichannel audio

:process: This method triggers the compositing.

Expand All @@ -16,39 +17,39 @@

:control source:

The bufNum of the source buffer.
The name of the source buffer.

:control startFrame:

The starting point (in samples) from which to copy in the source buffer.

:control numFrames:

The duration (in samples) to copy from the source buffer. The default (-1) copies the full lenght of the buffer.
The duration (in samples) to copy from the source buffer. The default (-1) copies the full length of the buffer.

:control startChan:

The first channel from which to copy in the source buffer.

:control numChans:

The number of channels from which to copy in the source buffer. This parameter will wrap around the number of channels in the source buffer. The default (-1) copies all of the buffer's channel.
The number of channels from which to copy in the source buffer. This parameter will wrap around the number of channels in the source buffer. The default (-1) copies all of the buffer's channels.

:control gain:

The gain applied to the samples to be copied from the source buffer.

:control destination:

The bufNum of the destination buffer.
The name of the destination buffer.

:control destStartFrame:

The time offset (in samples) in the destination buffer to start writing the source at. The destination buffer will be resized if the portion to copy is overflowing.

:control destStartChan:

The channel offest in the destination buffer to start writing the source at. The destination buffer will be resized if the number of channels to copy is overflowing.
The channel offset in the destination buffer to start writing the source at. The destination buffer will be resized if the number of channels to copy is overflowing.

:control destGain:

Expand Down
3 changes: 2 additions & 1 deletion doc/BufFlatten.rst
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
:sc-categories: FluidCorpusManipulation
:sc-related: Classes/Buffer
:see-also: BufCompose, BufStats
:max-seealso: poke~, peek~, index~, buffer~
:description:
Flatten a multichannel |buffer| to a single channel. This can be useful to structure a buffer such that it can be added to a :fluid-obj:`DataSet`
:discussion:
Expand Down Expand Up @@ -42,7 +43,7 @@

:control startChan:

For multichannel ``source`` buffers, which which channel to begin the processing. The default is 0.
For multichannel ``source`` buffers, which channel to begin the processing. The default is 0.

:control numChans:

Expand Down
8 changes: 4 additions & 4 deletions doc/BufHPSS.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
HPSS takes in audio and divides it into two or three outputs, depending on the ``maskingMode``
* an harmonic component
* a percussive component
* a residual of the previous two if ``maskingMode`` is set to 2 (inter-dependant thresholds). See below.
* a residual of the previous two if ``maskingMode`` is set to 2 (interdependent thresholds). See below.

HPSS works by using median filters on the magnitudes of a spectrogram. It makes certain assumptions about what it is looking for in a sound: that in a spectrogram “percussive” elements tend to form vertical “ridges” (tall in frequency band, narrow in time), while stable “harmonic” elements tend to form horizontal “ridges” (narrow in frequency band, long in time). By using median filters across time and frequency respectively, we get initial estimates of the "harmonic-ness" and "percussive-ness" for every spectral bin of every spectral frame in the spectrogram. These are then combined into 'masks' that are applied to the original spectrogram in order to produce a harmonic and percussive output (and residual if ``maskingMode`` = 2).

The maskingMode parameter provides different approaches to combining estimates and producing masks. Some settings (especially in modes 1 & 2) will provide better separation but with more artefacts.

Driedger (2014) suggests that the size of the median filters don't affect the outcome as much as the ``fftSize``. with large FFT sizes, short percussive sounds have less representation, therefore the harmonic component is more strongly represented. The result is that many of the percussive sounds leak into the harmonic component. Small FFT sizes have less resolution in the frequency domain and often lead to a blurring of horizontal structures, therefore harmonic sounds tend to leak into the percussive component. As with all FFT based-processes, finding an FFT size that balances spectral and temporal resolution for a given source sound will benefit the use of this object.
Driedger (2014) suggests that the size of the median filters don't affect the outcome as much as the ``fftSize``. With large FFT sizes, short percussive sounds have less representation, therefore the harmonic component is more strongly represented. The result is that many of the percussive sounds leak into the harmonic component. Small FFT sizes have less resolution in the frequency domain and often lead to a blurring of horizontal structures, therefore harmonic sounds tend to leak into the percussive component. As with all FFT based-processes, finding an FFT size that balances spectral and temporal resolution for a given source sound will benefit the use of this object.

For more details visit https://learn.flucoma.org/reference/hpss

Expand Down Expand Up @@ -74,13 +74,13 @@
:enum:

:0:
Soft masks provide the fewest artefacts, but the weakest separation. Complimentary, soft masks are made for the harmonic and percussive parts by allocating some fraction of every magnitude in the spectrogram to each mask. The two resulting buffers will sum to exactly the original material. This mode uses soft mask in Fitzgerald's (2010) original method of 'Wiener-inspired' filtering.
Soft masks provide the fewest artefacts, but the weakest separation. Complimentary, soft masks are made for the harmonic and percussive parts by allocating some fraction of every magnitude in the spectrogram to each mask. The two resulting buffers will sum to exactly the original material. This mode uses a soft mask in Fitzgerald's (2010) original method of 'Wiener-inspired' filtering.

:1:
Binary masks provide better separation, but with more artefacts. The harmonic mask is constructed using a binary decision, based on whether a threshold is exceeded for every magnitude in the spectrogram (these are set using ``harmThreshFreq1``, ``harmThreshAmp1``, ``harmThreshFreq2``, ``harmThreshAmp2``, see below). The percussive mask is then formed as the inverse of the harmonic one, meaning that as above, the two components will sum to the original sound.

:2:
Soft masks (with a third stream containing a residual component). First, binary masks are made separately for the harmonic and percussive components using different thresholds (set with the respective ``harmThresh-`` and ``percThresh-`` parameters below). Because these masks aren't guaranteed to represent the entire spectrogram, any residual energy is considered as a third output. The independently created binary masks are converted to soft masks at the end of the process so that everything null sums.
Soft masks (with a third stream containing a residual component). First, binary masks are made separately for the harmonic and percussive components using different thresholds (set with the respective ``harmThresh-`` and ``percThresh-`` parameters below). Because these masks aren't guaranteed to represent the entire spectrogram, any residual energy is considered as a third output. The independently created binary masks are converted to soft masks at the end of the process so that everything null-sums.

:control harmThresh:

Expand Down
Loading

0 comments on commit dc45022

Please sign in to comment.