Buckets:
| import{s as aa,n as ra,o as na}from"../chunks/scheduler.6efaaf90.js";import{S as ua,i as sa,e as a,s as l,c as s,h as ma,a as r,d,b as i,f as m,g as c,j as n,k as u,l as ca,m as o,n as p,t as f,o as h,p as _}from"../chunks/index.eb3e1f0f.js";import{C as pa,H as b,E as fa}from"../chunks/MermaidChart.svelte_svelte_type_style_lang.16f13047.js";function ha(Wl){let g,kt,Pt,zt,w,Ft,v,Et,T,Bt,y,Vl="Helper module for audio processing.",Dt,$,Ol=`These functions and classes are only used internally, | |
| meaning an end-user shouldn’t need to access anything here.`,Kt,x,Nl='<li><a href="#module_utils/audio">utils/audio</a> <ul><li><em>static</em> <ul><li><a href="#module_utils/audio.RawAudio">.RawAudio</a> <ul><li><a href="#new_module_utils/audio.RawAudio_new"><code>new RawAudio(audio, sampling_rate)</code></a></li> <li><a href="#module_utils/audio.RawAudio+data"><code>.data</code></a> ⇒ <code>Float32Array</code></li> <li><a href="#module_utils/audio.RawAudio+toBlob"><code>.toBlob()</code></a> ⇒ <code>Blob</code></li> <li><a href="#module_utils/audio.RawAudio+save"><code>.save(path)</code></a> ⇒ <code>Promise.<void></code></li></ul></li> <li><del>[`.read_audio`](#module_utils/audio.read_audio)</del></li> <li><a href="#module_utils/audio.load_audio"><code>.load_audio(url, sampling_rate)</code></a> ⇒ <code>Promise.<Float32Array></code> <ul><li><a href="#module_utils/audio.load_audio..audio"><code>~audio</code></a> : <code>Float32Array</code></li></ul></li> <li><a href="#module_utils/audio.hanning"><code>.hanning(M)</code></a> ⇒ <code>Float64Array</code></li> <li><a href="#module_utils/audio.hamming"><code>.hamming(M)</code></a> ⇒ <code>Float64Array</code></li> <li><a href="#module_utils/audio.mel_filter_bank"><code>.mel_filter_bank(num_frequency_bins, num_mel_filters, min_frequency, max_frequency, sampling_rate, [norm], [mel_scale], [triangularize_in_mel_space])</code></a> ⇒ <code>Array</code></li> <li><a href="#module_utils/audio.spectrogram"><code>.spectrogram(waveform, window, frame_length, hop_length, options)</code></a> ⇒ <a href="#Tensor"><code>Promise.<Tensor></code></a></li> <li><a href="#module_utils/audio.window_function"><code>.window_function(window_length, name, options)</code></a> ⇒ <code>Float64Array</code></li></ul></li> <li><em>inner</em> <ul><li><a href="#module_utils/audio..generalized_cosine_window"><code>~generalized_cosine_window(M, a_0)</code></a> ⇒ <code>Float64Array</code></li> <li><a href="#module_utils/audio..hertz_to_mel"><code>~hertz_to_mel(freq, [mel_scale])</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio..mel_to_hertz"><code>~mel_to_hertz(mels, [mel_scale])</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio.._create_triangular_filter_bank"><code>~_create_triangular_filter_bank(fft_freqs, filter_freqs)</code></a> ⇒ <code>Array</code></li> <li><a href="#module_utils/audio..linspace"><code>~linspace(start, end, num)</code></a> ⇒</li> <li><a href="#module_utils/audio..padReflect"><code>~padReflect(array, left, right)</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio.._db_conversion_helper"><code>~_db_conversion_helper(spectrogram, factor, reference, min_value, db_range)</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio..amplitude_to_db"><code>~amplitude_to_db(spectrogram, [reference], [min_value], [db_range])</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio..power_to_db"><code>~power_to_db(spectrogram, [reference], [min_value], [db_range])</code></a> ⇒ <code>T</code></li> <li><a href="#module_utils/audio..encodeWAV"><code>~encodeWAV(chunks, rate)</code></a> ⇒ <code>Blob</code></li></ul></li></ul></li>',It,jt,St,H,Wt,A,Vt,L,Ul='<strong>Kind</strong>: static class of <a href="#module_utils/audio"><code>utils/audio</code></a>',Ot,M,Gl='<li><a href="#module_utils/audio.RawAudio">.RawAudio</a> <ul><li><a href="#new_module_utils/audio.RawAudio_new"><code>new RawAudio(audio, sampling_rate)</code></a></li> <li><a href="#module_utils/audio.RawAudio+data"><code>.data</code></a> ⇒ <code>Float32Array</code></li> <li><a href="#module_utils/audio.RawAudio+toBlob"><code>.toBlob()</code></a> ⇒ <code>Blob</code></li> <li><a href="#module_utils/audio.RawAudio+save"><code>.save(path)</code></a> ⇒ <code>Promise.<void></code></li></ul></li>',Nt,Ut,Gt,C,Jt,q,Qt,P,Jl="Create a new <code>RawAudio</code> object.",Xt,R,Ql="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>audio</td><td><code>Float32Array</code> | <code>Array</code></td><td><p>Audio data, either as a single <code>Float32Array</code> chunk or multiple <code>Float32Array</code> chunks.</p></td> </tr><tr><td>sampling_rate</td><td><code>number</code></td><td><p>Sampling rate of the audio data</p></td></tr></tbody>",Yt,Zt,ed,k,td,z,dd,F,Xl="Get the audio data, accumulating all chunks if necessary.",od,E,Yl='<strong>Kind</strong>: instance property of <a href="#module_utils/audio.RawAudio"><code>RawAudio</code></a><br/> <strong>Returns</strong>: <code>Float32Array</code> - The audio data.',ld,id,ad,B,rd,D,nd,K,Zl="Convert the audio to a blob.",ud,I,ei='<strong>Kind</strong>: instance method of <a href="#module_utils/audio.RawAudio"><code>RawAudio</code></a>',sd,md,cd,j,pd,S,fd,W,ti="Save the audio to a wav file.",hd,V,di='<strong>Kind</strong>: instance method of <a href="#module_utils/audio.RawAudio"><code>RawAudio</code></a>',_d,O,oi="<thead><tr><th>Param</th><th>Type</th></tr></thead> <tbody><tr><td>path</td><td><code>string</code></td></tr></tbody>",bd,gd,wd,N,vd,U,Td,G,li='<strong><em>Use <a href="load_audio">load_audio</a> instead.</em></strong>',yd,J,ii='<strong>Kind</strong>: static constant of <a href="#module_utils/audio"><code>utils/audio</code></a>',$d,xd,Hd,Q,Ad,X,Ld,Y,ai="Helper function to load audio from a path/URL.",Md,Z,ri='<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Promise.<Float32Array></code> - The decoded audio as a <code>Float32Array</code>.',Cd,ee,ni="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>url</td><td><code>string</code> | <code>URL</code></td><td><p>The path/URL to load the audio from.</p></td> </tr><tr><td>sampling_rate</td><td><code>number</code></td><td><p>The sampling rate to use when decoding the audio.</p></td></tr></tbody>",qd,Pd,Rd,te,kd,de,zd,oe,ui='<strong>Kind</strong>: inner property of <a href="#module_utils/audio.load_audio"><code>load_audio</code></a>',Fd,Ed,Bd,le,Dd,ie,Kd,ae,si=`Generates a Hanning window of length M. | |
| See <a href="https://numpy.org/doc/stable/reference/generated/numpy.hanning.html" rel="nofollow">https://numpy.org/doc/stable/reference/generated/numpy.hanning.html</a> for more information.`,Id,re,mi='<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Float64Array</code> - The generated Hanning window.',jd,ne,ci="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>M</td><td><code>number</code></td><td><p>The length of the Hanning window to generate.</p></td></tr></tbody>",Sd,Wd,Vd,ue,Od,se,Nd,me,pi=`Generates a Hamming window of length M. | |
| See <a href="https://numpy.org/doc/stable/reference/generated/numpy.hamming.html" rel="nofollow">https://numpy.org/doc/stable/reference/generated/numpy.hamming.html</a> for more information.`,Ud,ce,fi='<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Float64Array</code> - The generated Hamming window.',Gd,pe,hi="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>M</td><td><code>number</code></td><td><p>The length of the Hamming window to generate.</p></td></tr></tbody>",Jd,Qd,Xd,fe,Yd,he,Zd,_e,_i=`Creates a frequency bin conversion matrix used to obtain a mel spectrogram. This is called a <em>mel filter bank</em>, and | |
| various implementation exist, which differ in the number of filters, the shape of the filters, the way the filters | |
| are spaced, the bandwidth of the filters, and the manner in which the spectrum is warped. The goal of these | |
| features is to approximate the non-linear human perception of the variation in pitch with respect to the frequency.`,eo,be,bi=`<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Array</code> - Triangular filter bank matrix, which is a 2D array of shape (<code>num_frequency_bins</code>, <code>num_mel_filters</code>). | |
| This is a projection matrix to go from a spectrogram to a mel spectrogram.`,to,ge,gi=`<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>num_frequency_bins</td><td><code>number</code></td><td><p>Number of frequency bins (should be the same as <code>n_fft // 2 + 1</code> | |
| where <code>n_fft</code> is the size of the Fourier Transform used to compute the spectrogram).</p></td> </tr><tr><td>num_mel_filters</td><td><code>number</code></td><td><p>Number of mel filters to generate.</p></td> </tr><tr><td>min_frequency</td><td><code>number</code></td><td><p>Lowest frequency of interest in Hz.</p></td> </tr><tr><td>max_frequency</td><td><code>number</code></td><td><p>Highest frequency of interest in Hz. This should not exceed <code>sampling_rate / 2</code>.</p></td> </tr><tr><td>sampling_rate</td><td><code>number</code></td><td><p>Sample rate of the audio waveform.</p></td> </tr><tr><td>[norm]</td><td><code>string</code> | <code>null</code></td><td><p>If <code>"slaney"</code>, divide the triangular mel weights by the width of the mel band (area normalization).</p></td> </tr><tr><td>[mel_scale]</td><td><code>string</code></td><td><p>The mel frequency scale to use, <code>"htk"</code> or <code>"slaney"</code>.</p></td> </tr><tr><td>[triangularize_in_mel_space]</td><td><code>boolean</code></td><td><p>If this option is enabled, the triangular filter is applied in mel space rather than frequency space. | |
| This should be set to <code>true</code> in order to get the same results as <code>torchaudio</code> when computing mel filters.</p></td></tr></tbody>`,oo,lo,io,we,ao,ve,ro,Te,wi="Calculates a spectrogram over one waveform using the Short-Time Fourier Transform.",no,ye,vi="This function can create the following kinds of spectrograms:",uo,$e,Ti="<li>amplitude spectrogram (<code>power = 1.0</code>)</li> <li>power spectrogram (<code>power = 2.0</code>)</li> <li>complex-valued spectrogram (<code>power = None</code>)</li> <li>log spectrogram (use <code>log_mel</code> argument)</li> <li>mel spectrogram (provide <code>mel_filters</code>)</li> <li>log-mel spectrogram (provide <code>mel_filters</code> and <code>log_mel</code>)</li>",so,xe,yi=`In this implementation, the window is assumed to be zero-padded to have the same size as the analysis frame. | |
| A padded window can be obtained from <code>window_function()</code>. The FFT input buffer may be larger than the analysis frame, | |
| typically the next power of two.`,mo,He,$i='<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <a href="#Tensor"><code>Promise.<Tensor></code></a> - Spectrogram of shape <code>(num_frequency_bins, length)</code> (regular spectrogram) or shape <code>(num_mel_filters, length)</code> (mel spectrogram).',co,Ae,xi=`<thead><tr><th>Param</th><th>Type</th><th>Default</th><th>Description</th></tr></thead> <tbody><tr><td>waveform</td><td><code>Float32Array</code> | <code>Float64Array</code></td><td></td><td><p>The input waveform of shape <code>(length,)</code>. This must be a single real-valued, mono waveform.</p></td> </tr><tr><td>window</td><td><code>Float32Array</code> | <code>Float64Array</code></td><td></td><td><p>The windowing function to apply of shape <code>(frame_length,)</code>, including zero-padding if necessary. The actual window length may be | |
| shorter than <code>frame_length</code>, but we're assuming the array has already been zero-padded.</p></td> </tr><tr><td>frame_length</td><td><code>number</code></td><td></td><td><p>The length of the analysis frames in samples (a.k.a., <code>fft_length</code>).</p></td> </tr><tr><td>hop_length</td><td><code>number</code></td><td></td><td><p>The stride between successive analysis frames in samples.</p></td> </tr><tr><td>options</td><td><code>Object</code></td><td></td><td></td> </tr><tr><td>[options.fft_length]</td><td><code>number</code></td><td><code></code></td><td><p>The size of the FFT buffer in samples. This determines how many frequency bins the spectrogram will have. | |
| For optimal speed, this should be a power of two. If <code>null</code>, uses <code>frame_length</code>.</p></td> </tr><tr><td>[options.power]</td><td><code>number</code></td><td><code>1.0</code></td><td><p>If 1.0, returns the amplitude spectrogram. If 2.0, returns the power spectrogram. If <code>null</code>, returns complex numbers.</p></td> </tr><tr><td>[options.center]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>Whether to pad the waveform so that frame <code>t</code> is centered around time <code>t * hop_length</code>. If <code>false</code>, frame | |
| <code>t</code> will start at time <code>t * hop_length</code>.</p></td> </tr><tr><td>[options.pad_mode]</td><td><code>string</code></td><td><code>""reflect""</code></td><td><p>Padding mode used when <code>center</code> is <code>true</code>. Possible values are: <code>"constant"</code> (pad with zeros), | |
| <code>"edge"</code> (pad with edge values), <code>"reflect"</code> (pads with mirrored values).</p></td> </tr><tr><td>[options.onesided]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>If <code>true</code>, only computes the positive frequencies and returns a spectrogram containing <code>fft_length // 2 + 1</code> | |
| frequency bins. If <code>false</code>, also computes the negative frequencies and returns <code>fft_length</code> frequency bins.</p></td> </tr><tr><td>[options.preemphasis]</td><td><code>number</code></td><td><code></code></td><td><p>Coefficient for a low-pass filter that applies pre-emphasis before the DFT.</p></td> </tr><tr><td>[options.preemphasis_htk_flavor]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>Whether to apply the pre-emphasis filter in the HTK flavor.</p></td> </tr><tr><td>[options.mel_filters]</td><td><code>Array</code></td><td><code></code></td><td><p>The mel filter bank of shape <code>(num_freq_bins, num_mel_filters)</code>. | |
| If supplied, applies this filter bank to create a mel spectrogram.</p></td> </tr><tr><td>[options.mel_floor]</td><td><code>number</code></td><td><code>1e-10</code></td><td><p>Minimum value of mel frequency banks.</p></td> </tr><tr><td>[options.log_mel]</td><td><code>string</code></td><td><code>null</code></td><td><p>How to convert the spectrogram to log scale. Possible options are: | |
| <code>null</code> (don't convert), <code>"log"</code> (take the natural logarithm), <code>"log10"</code> (take the base-10 logarithm), <code>"dB"</code> (convert to decibels), | |
| <code>"log10_max_norm"</code> (take <code>log10</code>, then apply <code>(max(x, maxVal - 8) + 4) / 4</code> normalization, where <code>maxVal</code> is computed from data or given by <code>max_log_mel</code>). | |
| Can only be used when <code>power</code> is not <code>null</code>.</p></td> </tr><tr><td>[options.max_log_mel]</td><td><code>number</code></td><td><code></code></td><td><p>When <code>log_mel</code> is <code>"log10_max_norm"</code>, use this fixed value as the max instead of computing from data.</p></td> </tr><tr><td>[options.reference]</td><td><code>number</code></td><td><code>1.0</code></td><td><p>Sets the input spectrogram value that corresponds to 0 dB. For example, use <code>max(spectrogram)[0]</code> to set | |
| the loudest part to 0 dB. Must be greater than zero.</p></td> </tr><tr><td>[options.min_value]</td><td><code>number</code></td><td><code>1e-10</code></td><td><p>The spectrogram will be clipped to this minimum value before conversion to decibels, to avoid taking <code>log(0)</code>. | |
| For a power spectrogram, the default of <code>1e-10</code> corresponds to a minimum of -100 dB. For an amplitude spectrogram, the value <code>1e-5</code> corresponds to -100 dB. | |
| Must be greater than zero.</p></td> </tr><tr><td>[options.db_range]</td><td><code>number</code></td><td><code></code></td><td><p>Sets the maximum dynamic range in decibels. For example, if <code>db_range = 80</code>, the difference between the | |
| peak value and the smallest value will never be more than 80 dB. Must be greater than zero.</p></td> </tr><tr><td>[options.remove_dc_offset]</td><td><code>boolean</code></td><td><code></code></td><td><p>Subtract mean from waveform on each frame, applied before pre-emphasis. This should be set to <code>true</code> in | |
| order to get the same results as <code>torchaudio.compliance.kaldi.fbank</code> when computing mel filters.</p></td> </tr><tr><td>[options.max_num_frames]</td><td><code>number</code></td><td><code></code></td><td><p>If provided, limits the number of frames to compute to this value.</p></td> </tr><tr><td>[options.min_num_frames]</td><td><code>number</code></td><td><code></code></td><td><p>If provided, ensures the number of frames to compute is at least this value.</p></td> </tr><tr><td>[options.do_pad]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>If <code>true</code>, pads the output spectrogram to have <code>max_num_frames</code> frames.</p></td> </tr><tr><td>[options.transpose]</td><td><code>boolean</code></td><td><code>false</code></td><td><p>If <code>true</code>, the returned spectrogram will have shape <code>(num_frames, num_frequency_bins/num_mel_filters)</code>. If <code>false</code>, the returned spectrogram will have shape <code>(num_frequency_bins/num_mel_filters, num_frames)</code>.</p></td> </tr><tr><td>[options.mel_offset]</td><td><code>number</code></td><td><code>0</code></td><td><p>Offset to add to the mel spectrogram to avoid taking the log of zero.</p></td> </tr><tr><td>[options.mel_floor_mode]</td><td><code>string</code></td><td><code>""clamp""</code></td><td><p>If <code>mel_offset</code> is provided, this option determines how to apply it. If <code>"clamp"</code>, the mel spectrogram will be clamped to have a minimum value of <code>mel_offset</code>. If <code>"add"</code>, <code>mel_offset</code> will be added to all values of the mel spectrogram.</p></td></tr></tbody>`,po,fo,ho,Le,_o,Me,bo,Ce,Hi="Returns an array containing the specified window.",go,qe,Ai='<strong>Kind</strong>: static method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Float64Array</code> - The window of shape <code>(window_length,)</code> or <code>(frame_length,)</code>.',wo,Pe,Li=`<thead><tr><th>Param</th><th>Type</th><th>Default</th><th>Description</th></tr></thead> <tbody><tr><td>window_length</td><td><code>number</code></td><td></td><td><p>The length of the window in samples.</p></td> </tr><tr><td>name</td><td><code>string</code></td><td></td><td><p>The name of the window function.</p></td> </tr><tr><td>options</td><td><code>Object</code></td><td></td><td><p>Additional options.</p></td> </tr><tr><td>[options.periodic]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>Whether the window is periodic or symmetric.</p></td> </tr><tr><td>[options.frame_length]</td><td><code>number</code></td><td><code></code></td><td><p>The length of the analysis frames in samples. | |
| Provide a value for <code>frame_length</code> if the window is smaller than the frame length, so that it will be zero-padded.</p></td> </tr><tr><td>[options.center]</td><td><code>boolean</code></td><td><code>true</code></td><td><p>Whether to center the window inside the FFT buffer. Only used when <code>frame_length</code> is provided.</p></td></tr></tbody>`,vo,To,yo,Re,$o,ke,xo,ze,Mi=`Helper function to generate windows that are special cases of the generalized cosine window. | |
| See <a href="https://www.mathworks.com/help/signal/ug/generalized-cosine-windows.html" rel="nofollow">https://www.mathworks.com/help/signal/ug/generalized-cosine-windows.html</a> for more information.`,Ho,Fe,Ci='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Float64Array</code> - The generated window.',Ao,Ee,qi="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>M</td><td><code>number</code></td><td><p>Number of points in the output window. If zero or less, an empty array is returned.</p></td> </tr><tr><td>a_0</td><td><code>number</code></td><td><p>Offset for the generalized cosine window.</p></td></tr></tbody>",Lo,Mo,Co,Be,qo,De,Po,Ke,Pi='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a>',Ro,Ie,Ri="<thead><tr><th>Param</th><th>Type</th><th>Default</th></tr></thead> <tbody><tr><td>freq</td><td><code>T</code></td><td></td> </tr><tr><td>[mel_scale]</td><td><code>string</code></td><td><code>"htk"</code></td></tr></tbody>",ko,zo,Fo,je,Eo,Se,Bo,We,ki='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a>',Do,Ve,zi="<thead><tr><th>Param</th><th>Type</th><th>Default</th></tr></thead> <tbody><tr><td>mels</td><td><code>T</code></td><td></td> </tr><tr><td>[mel_scale]</td><td><code>string</code></td><td><code>"htk"</code></td></tr></tbody>",Ko,Io,jo,Oe,So,Ne,Wo,Ue,Fi="Creates a triangular filter bank.",Vo,Ge,Ei="Adapted from torchaudio and librosa.",Oo,Je,Bi='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Array</code> - of shape <code>(num_frequency_bins, num_mel_filters)</code>.',No,Qe,Di="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>fft_freqs</td><td><code>Float64Array</code></td><td><p>Discrete frequencies of the FFT bins in Hz, of shape <code>(num_frequency_bins,)</code>.</p></td> </tr><tr><td>filter_freqs</td><td><code>Float64Array</code></td><td><p>Center frequencies of the triangular filters to create, in Hz, of shape <code>(num_mel_filters,)</code>.</p></td></tr></tbody>",Uo,Go,Jo,Xe,Qo,Ye,Xo,Ze,Ki="Return evenly spaced numbers over a specified interval.",Yo,et,Ii='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>num</code> evenly spaced samples, calculated over the interval <code>[start, stop]</code>.',Zo,tt,ji="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>start</td><td><code>number</code></td><td><p>The starting value of the sequence.</p></td> </tr><tr><td>end</td><td><code>number</code></td><td><p>The end value of the sequence.</p></td> </tr><tr><td>num</td><td><code>number</code></td><td><p>Number of samples to generate.</p></td></tr></tbody>",el,tl,dl,dt,ol,ot,ll,lt,Si='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>T</code> - The padded array.',il,it,Wi="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>array</td><td><code>T</code></td><td><p>The array to pad.</p></td> </tr><tr><td>left</td><td><code>number</code></td><td><p>The amount of padding to add to the left.</p></td> </tr><tr><td>right</td><td><code>number</code></td><td><p>The amount of padding to add to the right.</p></td></tr></tbody>",al,rl,nl,at,ul,rt,sl,nt,Vi="Helper function to compute <code>amplitude_to_db</code> and <code>power_to_db</code>.",ml,ut,Oi='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a>',cl,st,Ni="<thead><tr><th>Param</th><th>Type</th></tr></thead> <tbody><tr><td>spectrogram</td><td><code>T</code></td> </tr><tr><td>factor</td><td><code>number</code></td> </tr><tr><td>reference</td><td><code>number</code></td> </tr><tr><td>min_value</td><td><code>number</code></td> </tr><tr><td>db_range</td><td><code>number</code></td></tr></tbody>",pl,fl,hl,mt,_l,ct,bl,pt,Ui=`Converts an amplitude spectrogram to the decibel scale. This computes <code>20 * log10(spectrogram / reference)</code>, | |
| using basic logarithm properties for numerical stability. NOTE: Operates in-place.`,gl,ft,Gi=`The motivation behind applying the log function on the (mel) spectrogram is that humans do not hear loudness on a | |
| linear scale. Generally to double the perceived volume of a sound we need to put 8 times as much energy into it. | |
| This means that large variations in energy may not sound all that different if the sound is loud to begin with. | |
| This compression operation makes the (mel) spectrogram features match more closely what humans actually hear.`,wl,ht,Ji='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>T</code> - The modified spectrogram in decibels.',vl,_t,Qi=`<thead><tr><th>Param</th><th>Type</th><th>Default</th><th>Description</th></tr></thead> <tbody><tr><td>spectrogram</td><td><code>T</code></td><td></td><td><p>The input amplitude (mel) spectrogram.</p></td> </tr><tr><td>[reference]</td><td><code>number</code></td><td><code>1.0</code></td><td><p>Sets the input spectrogram value that corresponds to 0 dB. | |
| For example, use <code>np.max(spectrogram)</code> to set the loudest part to 0 dB. Must be greater than zero.</p></td> </tr><tr><td>[min_value]</td><td><code>number</code></td><td><code>1e-5</code></td><td><p>The spectrogram will be clipped to this minimum value before conversion to decibels, | |
| to avoid taking <code>log(0)</code>. The default of <code>1e-5</code> corresponds to a minimum of -100 dB. Must be greater than zero.</p></td> </tr><tr><td>[db_range]</td><td><code>number</code></td><td><code></code></td><td><p>Sets the maximum dynamic range in decibels. For example, if <code>db_range = 80</code>, the | |
| difference between the peak value and the smallest value will never be more than 80 dB. Must be greater than zero.</p></td></tr></tbody>`,Tl,yl,$l,bt,xl,gt,Hl,wt,Xi=`Converts a power spectrogram to the decibel scale. This computes <code>10 * log10(spectrogram / reference)</code>, | |
| using basic logarithm properties for numerical stability. NOTE: Operates in-place.`,Al,vt,Yi=`The motivation behind applying the log function on the (mel) spectrogram is that humans do not hear loudness on a | |
| linear scale. Generally to double the perceived volume of a sound we need to put 8 times as much energy into it. | |
| This means that large variations in energy may not sound all that different if the sound is loud to begin with. | |
| This compression operation makes the (mel) spectrogram features match more closely what humans actually hear.`,Ll,Tt,Zi="Based on the implementation of <code>librosa.power_to_db</code>.",Ml,yt,ea='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>T</code> - The modified spectrogram in decibels.',Cl,$t,ta=`<thead><tr><th>Param</th><th>Type</th><th>Default</th><th>Description</th></tr></thead> <tbody><tr><td>spectrogram</td><td><code>T</code></td><td></td><td><p>The input power (mel) spectrogram. Note that a power spectrogram has the amplitudes squared!</p></td> </tr><tr><td>[reference]</td><td><code>number</code></td><td><code>1.0</code></td><td><p>Sets the input spectrogram value that corresponds to 0 dB. | |
| For example, use <code>np.max(spectrogram)</code> to set the loudest part to 0 dB. Must be greater than zero.</p></td> </tr><tr><td>[min_value]</td><td><code>number</code></td><td><code>1e-10</code></td><td><p>The spectrogram will be clipped to this minimum value before conversion to decibels, | |
| to avoid taking <code>log(0)</code>. The default of <code>1e-10</code> corresponds to a minimum of -100 dB. Must be greater than zero.</p></td> </tr><tr><td>[db_range]</td><td><code>number</code></td><td><code></code></td><td><p>Sets the maximum dynamic range in decibels. For example, if <code>db_range = 80</code>, the | |
| difference between the peak value and the smallest value will never be more than 80 dB. Must be greater than zero.</p></td></tr></tbody>`,ql,Pl,Rl,xt,kl,Ht,zl,At,da=`Efficiently encode audio data to a WAV file. | |
| WAV file specs : <a href="https://en.wikipedia.org/wiki/WAV#WAV_File_header" rel="nofollow">https://en.wikipedia.org/wiki/WAV#WAV_File_header</a>`,Fl,Lt,oa='Adapted from <a href="https://www.npmjs.com/package/audiobuffer-to-wav" rel="nofollow">https://www.npmjs.com/package/audiobuffer-to-wav</a>',El,Mt,la='<strong>Kind</strong>: inner method of <a href="#module_utils/audio"><code>utils/audio</code></a><br/> <strong>Returns</strong>: <code>Blob</code> - The WAV file as a Blob.',Bl,Ct,ia="<thead><tr><th>Param</th><th>Type</th><th>Description</th></tr></thead> <tbody><tr><td>chunks</td><td><code>Array</code></td><td><p>The audio samples.</p></td> </tr><tr><td>rate</td><td><code>number</code></td><td><p>The sample rate.</p></td></tr></tbody>",Dl,Kl,Il,qt,jl,Rt,Sl;return v=new pa({props:{containerStyle:"float: right; margin-left: 10px; display: inline-flex; position: relative; z-index: 10;"}}),T=new b({props:{title:"utils/audio",local:"utilsaudio",headingTag:"h1"}}),A=new b({props:{title:"utils/audio.RawAudio",local:"utilsaudiorawaudio",headingTag:"h2"}}),q=new b({props:{title:"new RawAudio(audio, sampling_rate)",local:"new-rawaudioaudio-samplingrate",headingTag:"h3"}}),z=new b({props:{title:"rawAudio.data ⇒ Float32Array",local:"rawaudiodata--float32array",headingTag:"h3"}}),D=new b({props:{title:"rawAudio.toBlob() ⇒ Blob",local:"rawaudiotoblob--blob",headingTag:"h3"}}),S=new b({props:{title:"rawAudio.save(path) ⇒ Promise. < void >",local:"rawaudiosavepath--promise--void-",headingTag:"h3"}}),U=new b({props:{title:"<del> utils/audio.read_audio </del>",local:"del-utilsaudioreadaudio-del",headingTag:"h2"}}),X=new b({props:{title:"utils/audio.load_audio(url, sampling_rate) ⇒ Promise. < Float32Array >",local:"utilsaudioloadaudiourl-samplingrate--promise--float32array-",headingTag:"h2"}}),de=new b({props:{title:"load_audio~audio : Float32Array",local:"loadaudioaudio--float32array",headingTag:"h3"}}),ie=new b({props:{title:"utils/audio.hanning(M) ⇒ Float64Array",local:"utilsaudiohanningm--float64array",headingTag:"h2"}}),se=new b({props:{title:"utils/audio.hamming(M) ⇒ Float64Array",local:"utilsaudiohammingm--float64array",headingTag:"h2"}}),he=new b({props:{title:"utils/audio.mel_filter_bank(num_frequency_bins, num_mel_filters, min_frequency, max_frequency, sampling_rate, [norm], [mel_scale], [triangularize_in_mel_space]) ⇒ Array",local:"utilsaudiomelfilterbanknumfrequencybins-nummelfilters-minfrequency-maxfrequency-samplingrate-norm-melscale-triangularizeinmelspace--array",headingTag:"h2"}}),ve=new b({props:{title:"utils/audio.spectrogram(waveform, window, frame_length, hop_length, options) ⇒ Promise. < Tensor >",local:"utilsaudiospectrogramwaveform-window-framelength-hoplength-options--promise--tensor-",headingTag:"h2"}}),Me=new b({props:{title:"utils/audio.window_function(window_length, name, options) ⇒ Float64Array",local:"utilsaudiowindowfunctionwindowlength-name-options--float64array",headingTag:"h2"}}),ke=new b({props:{title:"utils/audio~generalized_cosine_window(M, a_0) ⇒ Float64Array",local:"utilsaudiogeneralizedcosinewindowm-a0--float64array",headingTag:"h2"}}),De=new b({props:{title:"utils/audio~hertz_to_mel(freq, [mel_scale]) ⇒ T",local:"utilsaudiohertztomelfreq-melscale--t",headingTag:"h2"}}),Se=new b({props:{title:"utils/audio~mel_to_hertz(mels, [mel_scale]) ⇒ T",local:"utilsaudiomeltohertzmels-melscale--t",headingTag:"h2"}}),Ne=new b({props:{title:"utils/audio~_create_triangular_filter_bank(fft_freqs, filter_freqs) ⇒ Array",local:"utilsaudiocreatetriangularfilterbankfftfreqs-filterfreqs--array",headingTag:"h2"}}),Ye=new b({props:{title:"utils/audio~linspace(start, end, num) ⇒",local:"utilsaudiolinspacestart-end-num-",headingTag:"h2"}}),ot=new b({props:{title:"utils/audio~padReflect(array, left, right) ⇒ T",local:"utilsaudiopadreflectarray-left-right--t",headingTag:"h2"}}),rt=new b({props:{title:"utils/audio~_db_conversion_helper(spectrogram, factor, reference, min_value, db_range) ⇒ T",local:"utilsaudiodbconversionhelperspectrogram-factor-reference-minvalue-dbrange--t",headingTag:"h2"}}),ct=new b({props:{title:"utils/audio~amplitude_to_db(spectrogram, [reference], [min_value], [db_range]) ⇒ T",local:"utilsaudioamplitudetodbspectrogram-reference-minvalue-dbrange--t",headingTag:"h2"}}),gt=new b({props:{title:"utils/audio~power_to_db(spectrogram, [reference], [min_value], [db_range]) ⇒ T",local:"utilsaudiopowertodbspectrogram-reference-minvalue-dbrange--t",headingTag:"h2"}}),Ht=new b({props:{title:"utils/audio~encodeWAV(chunks, rate) ⇒ Blob",local:"utilsaudioencodewavchunks-rate--blob",headingTag:"h2"}}),qt=new fa({props:{source:"https://github.com/huggingface/transformers.js/blob/main/packages/transformers/docs/source/api/utils/audio.md"}}),{c(){g=a("meta"),kt=l(),Pt=a("p"),zt=l(),w=a("a"),Ft=l(),s(v.$$.fragment),Et=l(),s(T.$$.fragment),Bt=l(),y=a("p"),y.textContent=Vl,Dt=l(),$=a("p"),$.textContent=Ol,Kt=l(),x=a("ul"),x.innerHTML=Nl,It=l(),jt=a("hr"),St=l(),H=a("a"),Wt=l(),s(A.$$.fragment),Vt=l(),L=a("p"),L.innerHTML=Ul,Ot=l(),M=a("ul"),M.innerHTML=Gl,Nt=l(),Ut=a("hr"),Gt=l(),C=a("a"),Jt=l(),s(q.$$.fragment),Qt=l(),P=a("p"),P.innerHTML=Jl,Xt=l(),R=a("table"),R.innerHTML=Ql,Yt=l(),Zt=a("hr"),ed=l(),k=a("a"),td=l(),s(z.$$.fragment),dd=l(),F=a("p"),F.textContent=Xl,od=l(),E=a("p"),E.innerHTML=Yl,ld=l(),id=a("hr"),ad=l(),B=a("a"),rd=l(),s(D.$$.fragment),nd=l(),K=a("p"),K.textContent=Zl,ud=l(),I=a("p"),I.innerHTML=ei,sd=l(),md=a("hr"),cd=l(),j=a("a"),pd=l(),s(S.$$.fragment),fd=l(),W=a("p"),W.textContent=ti,hd=l(),V=a("p"),V.innerHTML=di,_d=l(),O=a("table"),O.innerHTML=oi,bd=l(),gd=a("hr"),wd=l(),N=a("a"),vd=l(),s(U.$$.fragment),Td=l(),G=a("p"),G.innerHTML=li,yd=l(),J=a("p"),J.innerHTML=ii,$d=l(),xd=a("hr"),Hd=l(),Q=a("a"),Ad=l(),s(X.$$.fragment),Ld=l(),Y=a("p"),Y.textContent=ai,Md=l(),Z=a("p"),Z.innerHTML=ri,Cd=l(),ee=a("table"),ee.innerHTML=ni,qd=l(),Pd=a("hr"),Rd=l(),te=a("a"),kd=l(),s(de.$$.fragment),zd=l(),oe=a("p"),oe.innerHTML=ui,Fd=l(),Ed=a("hr"),Bd=l(),le=a("a"),Dd=l(),s(ie.$$.fragment),Kd=l(),ae=a("p"),ae.innerHTML=si,Id=l(),re=a("p"),re.innerHTML=mi,jd=l(),ne=a("table"),ne.innerHTML=ci,Sd=l(),Wd=a("hr"),Vd=l(),ue=a("a"),Od=l(),s(se.$$.fragment),Nd=l(),me=a("p"),me.innerHTML=pi,Ud=l(),ce=a("p"),ce.innerHTML=fi,Gd=l(),pe=a("table"),pe.innerHTML=hi,Jd=l(),Qd=a("hr"),Xd=l(),fe=a("a"),Yd=l(),s(he.$$.fragment),Zd=l(),_e=a("p"),_e.innerHTML=_i,eo=l(),be=a("p"),be.innerHTML=bi,to=l(),ge=a("table"),ge.innerHTML=gi,oo=l(),lo=a("hr"),io=l(),we=a("a"),ao=l(),s(ve.$$.fragment),ro=l(),Te=a("p"),Te.textContent=wi,no=l(),ye=a("p"),ye.textContent=vi,uo=l(),$e=a("ul"),$e.innerHTML=Ti,so=l(),xe=a("p"),xe.innerHTML=yi,mo=l(),He=a("p"),He.innerHTML=$i,co=l(),Ae=a("table"),Ae.innerHTML=xi,po=l(),fo=a("hr"),ho=l(),Le=a("a"),_o=l(),s(Me.$$.fragment),bo=l(),Ce=a("p"),Ce.textContent=Hi,go=l(),qe=a("p"),qe.innerHTML=Ai,wo=l(),Pe=a("table"),Pe.innerHTML=Li,vo=l(),To=a("hr"),yo=l(),Re=a("a"),$o=l(),s(ke.$$.fragment),xo=l(),ze=a("p"),ze.innerHTML=Mi,Ho=l(),Fe=a("p"),Fe.innerHTML=Ci,Ao=l(),Ee=a("table"),Ee.innerHTML=qi,Lo=l(),Mo=a("hr"),Co=l(),Be=a("a"),qo=l(),s(De.$$.fragment),Po=l(),Ke=a("p"),Ke.innerHTML=Pi,Ro=l(),Ie=a("table"),Ie.innerHTML=Ri,ko=l(),zo=a("hr"),Fo=l(),je=a("a"),Eo=l(),s(Se.$$.fragment),Bo=l(),We=a("p"),We.innerHTML=ki,Do=l(),Ve=a("table"),Ve.innerHTML=zi,Ko=l(),Io=a("hr"),jo=l(),Oe=a("a"),So=l(),s(Ne.$$.fragment),Wo=l(),Ue=a("p"),Ue.textContent=Fi,Vo=l(),Ge=a("p"),Ge.textContent=Ei,Oo=l(),Je=a("p"),Je.innerHTML=Bi,No=l(),Qe=a("table"),Qe.innerHTML=Di,Uo=l(),Go=a("hr"),Jo=l(),Xe=a("a"),Qo=l(),s(Ye.$$.fragment),Xo=l(),Ze=a("p"),Ze.textContent=Ki,Yo=l(),et=a("p"),et.innerHTML=Ii,Zo=l(),tt=a("table"),tt.innerHTML=ji,el=l(),tl=a("hr"),dl=l(),dt=a("a"),ol=l(),s(ot.$$.fragment),ll=l(),lt=a("p"),lt.innerHTML=Si,il=l(),it=a("table"),it.innerHTML=Wi,al=l(),rl=a("hr"),nl=l(),at=a("a"),ul=l(),s(rt.$$.fragment),sl=l(),nt=a("p"),nt.innerHTML=Vi,ml=l(),ut=a("p"),ut.innerHTML=Oi,cl=l(),st=a("table"),st.innerHTML=Ni,pl=l(),fl=a("hr"),hl=l(),mt=a("a"),_l=l(),s(ct.$$.fragment),bl=l(),pt=a("p"),pt.innerHTML=Ui,gl=l(),ft=a("p"),ft.textContent=Gi,wl=l(),ht=a("p"),ht.innerHTML=Ji,vl=l(),_t=a("table"),_t.innerHTML=Qi,Tl=l(),yl=a("hr"),$l=l(),bt=a("a"),xl=l(),s(gt.$$.fragment),Hl=l(),wt=a("p"),wt.innerHTML=Xi,Al=l(),vt=a("p"),vt.textContent=Yi,Ll=l(),Tt=a("p"),Tt.innerHTML=Zi,Ml=l(),yt=a("p"),yt.innerHTML=ea,Cl=l(),$t=a("table"),$t.innerHTML=ta,ql=l(),Pl=a("hr"),Rl=l(),xt=a("a"),kl=l(),s(Ht.$$.fragment),zl=l(),At=a("p"),At.innerHTML=da,Fl=l(),Lt=a("p"),Lt.innerHTML=oa,El=l(),Mt=a("p"),Mt.innerHTML=la,Bl=l(),Ct=a("table"),Ct.innerHTML=ia,Dl=l(),Kl=a("hr"),Il=l(),s(qt.$$.fragment),jl=l(),Rt=a("p"),this.h()},l(e){const t=ma("svelte-u9bgzb",document.head);g=r(t,"META",{name:!0,content:!0}),t.forEach(d),kt=i(e),Pt=r(e,"P",{}),m(Pt).forEach(d),zt=i(e),w=r(e,"A",{id:!0,class:!0}),m(w).forEach(d),Ft=i(e),c(v.$$.fragment,e),Et=i(e),c(T.$$.fragment,e),Bt=i(e),y=r(e,"P",{"data-svelte-h":!0}),n(y)!=="svelte-1u3vk4m"&&(y.textContent=Vl),Dt=i(e),$=r(e,"P",{"data-svelte-h":!0}),n($)!=="svelte-il3kl8"&&($.textContent=Ol),Kt=i(e),x=r(e,"UL",{"data-svelte-h":!0}),n(x)!=="svelte-1lyp1qg"&&(x.innerHTML=Nl),It=i(e),jt=r(e,"HR",{}),St=i(e),H=r(e,"A",{id:!0,class:!0}),m(H).forEach(d),Wt=i(e),c(A.$$.fragment,e),Vt=i(e),L=r(e,"P",{"data-svelte-h":!0}),n(L)!=="svelte-1s2dpoa"&&(L.innerHTML=Ul),Ot=i(e),M=r(e,"UL",{"data-svelte-h":!0}),n(M)!=="svelte-1dx877j"&&(M.innerHTML=Gl),Nt=i(e),Ut=r(e,"HR",{}),Gt=i(e),C=r(e,"A",{id:!0,class:!0}),m(C).forEach(d),Jt=i(e),c(q.$$.fragment,e),Qt=i(e),P=r(e,"P",{"data-svelte-h":!0}),n(P)!=="svelte-1a89sw5"&&(P.innerHTML=Jl),Xt=i(e),R=r(e,"TABLE",{"data-svelte-h":!0}),n(R)!=="svelte-90rnkj"&&(R.innerHTML=Ql),Yt=i(e),Zt=r(e,"HR",{}),ed=i(e),k=r(e,"A",{id:!0,class:!0}),m(k).forEach(d),td=i(e),c(z.$$.fragment,e),dd=i(e),F=r(e,"P",{"data-svelte-h":!0}),n(F)!=="svelte-3yy9bz"&&(F.textContent=Xl),od=i(e),E=r(e,"P",{"data-svelte-h":!0}),n(E)!=="svelte-1ujh659"&&(E.innerHTML=Yl),ld=i(e),id=r(e,"HR",{}),ad=i(e),B=r(e,"A",{id:!0,class:!0}),m(B).forEach(d),rd=i(e),c(D.$$.fragment,e),nd=i(e),K=r(e,"P",{"data-svelte-h":!0}),n(K)!=="svelte-m879bd"&&(K.textContent=Zl),ud=i(e),I=r(e,"P",{"data-svelte-h":!0}),n(I)!=="svelte-ugrjp2"&&(I.innerHTML=ei),sd=i(e),md=r(e,"HR",{}),cd=i(e),j=r(e,"A",{id:!0,class:!0}),m(j).forEach(d),pd=i(e),c(S.$$.fragment,e),fd=i(e),W=r(e,"P",{"data-svelte-h":!0}),n(W)!=="svelte-10oc88s"&&(W.textContent=ti),hd=i(e),V=r(e,"P",{"data-svelte-h":!0}),n(V)!=="svelte-ugrjp2"&&(V.innerHTML=di),_d=i(e),O=r(e,"TABLE",{"data-svelte-h":!0}),n(O)!=="svelte-f03x1m"&&(O.innerHTML=oi),bd=i(e),gd=r(e,"HR",{}),wd=i(e),N=r(e,"A",{id:!0,class:!0}),m(N).forEach(d),vd=i(e),c(U.$$.fragment,e),Td=i(e),G=r(e,"P",{"data-svelte-h":!0}),n(G)!=="svelte-b46hp8"&&(G.innerHTML=li),yd=i(e),J=r(e,"P",{"data-svelte-h":!0}),n(J)!=="svelte-1tn0kms"&&(J.innerHTML=ii),$d=i(e),xd=r(e,"HR",{}),Hd=i(e),Q=r(e,"A",{id:!0,class:!0}),m(Q).forEach(d),Ad=i(e),c(X.$$.fragment,e),Ld=i(e),Y=r(e,"P",{"data-svelte-h":!0}),n(Y)!=="svelte-151kq4z"&&(Y.textContent=ai),Md=i(e),Z=r(e,"P",{"data-svelte-h":!0}),n(Z)!=="svelte-wzwr9x"&&(Z.innerHTML=ri),Cd=i(e),ee=r(e,"TABLE",{"data-svelte-h":!0}),n(ee)!=="svelte-1u23bjg"&&(ee.innerHTML=ni),qd=i(e),Pd=r(e,"HR",{}),Rd=i(e),te=r(e,"A",{id:!0,class:!0}),m(te).forEach(d),kd=i(e),c(de.$$.fragment,e),zd=i(e),oe=r(e,"P",{"data-svelte-h":!0}),n(oe)!=="svelte-vz2lqx"&&(oe.innerHTML=ui),Fd=i(e),Ed=r(e,"HR",{}),Bd=i(e),le=r(e,"A",{id:!0,class:!0}),m(le).forEach(d),Dd=i(e),c(ie.$$.fragment,e),Kd=i(e),ae=r(e,"P",{"data-svelte-h":!0}),n(ae)!=="svelte-13ns2vg"&&(ae.innerHTML=si),Id=i(e),re=r(e,"P",{"data-svelte-h":!0}),n(re)!=="svelte-187ugov"&&(re.innerHTML=mi),jd=i(e),ne=r(e,"TABLE",{"data-svelte-h":!0}),n(ne)!=="svelte-1x4zay3"&&(ne.innerHTML=ci),Sd=i(e),Wd=r(e,"HR",{}),Vd=i(e),ue=r(e,"A",{id:!0,class:!0}),m(ue).forEach(d),Od=i(e),c(se.$$.fragment,e),Nd=i(e),me=r(e,"P",{"data-svelte-h":!0}),n(me)!=="svelte-8gymva"&&(me.innerHTML=pi),Ud=i(e),ce=r(e,"P",{"data-svelte-h":!0}),n(ce)!=="svelte-1dyre01"&&(ce.innerHTML=fi),Gd=i(e),pe=r(e,"TABLE",{"data-svelte-h":!0}),n(pe)!=="svelte-io80jx"&&(pe.innerHTML=hi),Jd=i(e),Qd=r(e,"HR",{}),Xd=i(e),fe=r(e,"A",{id:!0,class:!0}),m(fe).forEach(d),Yd=i(e),c(he.$$.fragment,e),Zd=i(e),_e=r(e,"P",{"data-svelte-h":!0}),n(_e)!=="svelte-ke4v6b"&&(_e.innerHTML=_i),eo=i(e),be=r(e,"P",{"data-svelte-h":!0}),n(be)!=="svelte-1td0sb4"&&(be.innerHTML=bi),to=i(e),ge=r(e,"TABLE",{"data-svelte-h":!0}),n(ge)!=="svelte-vzsu9f"&&(ge.innerHTML=gi),oo=i(e),lo=r(e,"HR",{}),io=i(e),we=r(e,"A",{id:!0,class:!0}),m(we).forEach(d),ao=i(e),c(ve.$$.fragment,e),ro=i(e),Te=r(e,"P",{"data-svelte-h":!0}),n(Te)!=="svelte-10mwufd"&&(Te.textContent=wi),no=i(e),ye=r(e,"P",{"data-svelte-h":!0}),n(ye)!=="svelte-zfp2ya"&&(ye.textContent=vi),uo=i(e),$e=r(e,"UL",{"data-svelte-h":!0}),n($e)!=="svelte-14mziv8"&&($e.innerHTML=Ti),so=i(e),xe=r(e,"P",{"data-svelte-h":!0}),n(xe)!=="svelte-iwx6w9"&&(xe.innerHTML=yi),mo=i(e),He=r(e,"P",{"data-svelte-h":!0}),n(He)!=="svelte-1shoq4k"&&(He.innerHTML=$i),co=i(e),Ae=r(e,"TABLE",{"data-svelte-h":!0}),n(Ae)!=="svelte-1vbe6de"&&(Ae.innerHTML=xi),po=i(e),fo=r(e,"HR",{}),ho=i(e),Le=r(e,"A",{id:!0,class:!0}),m(Le).forEach(d),_o=i(e),c(Me.$$.fragment,e),bo=i(e),Ce=r(e,"P",{"data-svelte-h":!0}),n(Ce)!=="svelte-13l1rbm"&&(Ce.textContent=Hi),go=i(e),qe=r(e,"P",{"data-svelte-h":!0}),n(qe)!=="svelte-9ixqdv"&&(qe.innerHTML=Ai),wo=i(e),Pe=r(e,"TABLE",{"data-svelte-h":!0}),n(Pe)!=="svelte-h693em"&&(Pe.innerHTML=Li),vo=i(e),To=r(e,"HR",{}),yo=i(e),Re=r(e,"A",{id:!0,class:!0}),m(Re).forEach(d),$o=i(e),c(ke.$$.fragment,e),xo=i(e),ze=r(e,"P",{"data-svelte-h":!0}),n(ze)!=="svelte-1lyeqxj"&&(ze.innerHTML=Mi),Ho=i(e),Fe=r(e,"P",{"data-svelte-h":!0}),n(Fe)!=="svelte-xu9700"&&(Fe.innerHTML=Ci),Ao=i(e),Ee=r(e,"TABLE",{"data-svelte-h":!0}),n(Ee)!=="svelte-11w0boh"&&(Ee.innerHTML=qi),Lo=i(e),Mo=r(e,"HR",{}),Co=i(e),Be=r(e,"A",{id:!0,class:!0}),m(Be).forEach(d),qo=i(e),c(De.$$.fragment,e),Po=i(e),Ke=r(e,"P",{"data-svelte-h":!0}),n(Ke)!=="svelte-5cebk5"&&(Ke.innerHTML=Pi),Ro=i(e),Ie=r(e,"TABLE",{"data-svelte-h":!0}),n(Ie)!=="svelte-1w6ehfm"&&(Ie.innerHTML=Ri),ko=i(e),zo=r(e,"HR",{}),Fo=i(e),je=r(e,"A",{id:!0,class:!0}),m(je).forEach(d),Eo=i(e),c(Se.$$.fragment,e),Bo=i(e),We=r(e,"P",{"data-svelte-h":!0}),n(We)!=="svelte-5cebk5"&&(We.innerHTML=ki),Do=i(e),Ve=r(e,"TABLE",{"data-svelte-h":!0}),n(Ve)!=="svelte-io7ocd"&&(Ve.innerHTML=zi),Ko=i(e),Io=r(e,"HR",{}),jo=i(e),Oe=r(e,"A",{id:!0,class:!0}),m(Oe).forEach(d),So=i(e),c(Ne.$$.fragment,e),Wo=i(e),Ue=r(e,"P",{"data-svelte-h":!0}),n(Ue)!=="svelte-uj0il7"&&(Ue.textContent=Fi),Vo=i(e),Ge=r(e,"P",{"data-svelte-h":!0}),n(Ge)!=="svelte-srmfwi"&&(Ge.textContent=Ei),Oo=i(e),Je=r(e,"P",{"data-svelte-h":!0}),n(Je)!=="svelte-1stn33f"&&(Je.innerHTML=Bi),No=i(e),Qe=r(e,"TABLE",{"data-svelte-h":!0}),n(Qe)!=="svelte-2x9dyx"&&(Qe.innerHTML=Di),Uo=i(e),Go=r(e,"HR",{}),Jo=i(e),Xe=r(e,"A",{id:!0,class:!0}),m(Xe).forEach(d),Qo=i(e),c(Ye.$$.fragment,e),Xo=i(e),Ze=r(e,"P",{"data-svelte-h":!0}),n(Ze)!=="svelte-osjtvn"&&(Ze.textContent=Ki),Yo=i(e),et=r(e,"P",{"data-svelte-h":!0}),n(et)!=="svelte-bfmjcl"&&(et.innerHTML=Ii),Zo=i(e),tt=r(e,"TABLE",{"data-svelte-h":!0}),n(tt)!=="svelte-c7ztlp"&&(tt.innerHTML=ji),el=i(e),tl=r(e,"HR",{}),dl=i(e),dt=r(e,"A",{id:!0,class:!0}),m(dt).forEach(d),ol=i(e),c(ot.$$.fragment,e),ll=i(e),lt=r(e,"P",{"data-svelte-h":!0}),n(lt)!=="svelte-115nnpl"&&(lt.innerHTML=Si),il=i(e),it=r(e,"TABLE",{"data-svelte-h":!0}),n(it)!=="svelte-6p81mk"&&(it.innerHTML=Wi),al=i(e),rl=r(e,"HR",{}),nl=i(e),at=r(e,"A",{id:!0,class:!0}),m(at).forEach(d),ul=i(e),c(rt.$$.fragment,e),sl=i(e),nt=r(e,"P",{"data-svelte-h":!0}),n(nt)!=="svelte-9t3wul"&&(nt.innerHTML=Vi),ml=i(e),ut=r(e,"P",{"data-svelte-h":!0}),n(ut)!=="svelte-5cebk5"&&(ut.innerHTML=Oi),cl=i(e),st=r(e,"TABLE",{"data-svelte-h":!0}),n(st)!=="svelte-heeupf"&&(st.innerHTML=Ni),pl=i(e),fl=r(e,"HR",{}),hl=i(e),mt=r(e,"A",{id:!0,class:!0}),m(mt).forEach(d),_l=i(e),c(ct.$$.fragment,e),bl=i(e),pt=r(e,"P",{"data-svelte-h":!0}),n(pt)!=="svelte-93lmwr"&&(pt.innerHTML=Ui),gl=i(e),ft=r(e,"P",{"data-svelte-h":!0}),n(ft)!=="svelte-12zo44d"&&(ft.textContent=Gi),wl=i(e),ht=r(e,"P",{"data-svelte-h":!0}),n(ht)!=="svelte-1d363v6"&&(ht.innerHTML=Ji),vl=i(e),_t=r(e,"TABLE",{"data-svelte-h":!0}),n(_t)!=="svelte-1wpe278"&&(_t.innerHTML=Qi),Tl=i(e),yl=r(e,"HR",{}),$l=i(e),bt=r(e,"A",{id:!0,class:!0}),m(bt).forEach(d),xl=i(e),c(gt.$$.fragment,e),Hl=i(e),wt=r(e,"P",{"data-svelte-h":!0}),n(wt)!=="svelte-1dxatci"&&(wt.innerHTML=Xi),Al=i(e),vt=r(e,"P",{"data-svelte-h":!0}),n(vt)!=="svelte-12zo44d"&&(vt.textContent=Yi),Ll=i(e),Tt=r(e,"P",{"data-svelte-h":!0}),n(Tt)!=="svelte-1bxqqp"&&(Tt.innerHTML=Zi),Ml=i(e),yt=r(e,"P",{"data-svelte-h":!0}),n(yt)!=="svelte-1d363v6"&&(yt.innerHTML=ea),Cl=i(e),$t=r(e,"TABLE",{"data-svelte-h":!0}),n($t)!=="svelte-h9b3kb"&&($t.innerHTML=ta),ql=i(e),Pl=r(e,"HR",{}),Rl=i(e),xt=r(e,"A",{id:!0,class:!0}),m(xt).forEach(d),kl=i(e),c(Ht.$$.fragment,e),zl=i(e),At=r(e,"P",{"data-svelte-h":!0}),n(At)!=="svelte-ukuyih"&&(At.innerHTML=da),Fl=i(e),Lt=r(e,"P",{"data-svelte-h":!0}),n(Lt)!=="svelte-1dznmtc"&&(Lt.innerHTML=oa),El=i(e),Mt=r(e,"P",{"data-svelte-h":!0}),n(Mt)!=="svelte-3ss2et"&&(Mt.innerHTML=la),Bl=i(e),Ct=r(e,"TABLE",{"data-svelte-h":!0}),n(Ct)!=="svelte-d23aeu"&&(Ct.innerHTML=ia),Dl=i(e),Kl=r(e,"HR",{}),Il=i(e),c(qt.$$.fragment,e),jl=i(e),Rt=r(e,"P",{}),m(Rt).forEach(d),this.h()},h(){u(g,"name","hf:doc:metadata"),u(g,"content",_a),u(w,"id","module_utils/audio"),u(w,"class","group"),u(H,"id","module_utils/audio.RawAudio"),u(H,"class","group"),u(C,"id","new_module_utils/audio.RawAudio_new"),u(C,"class","group"),u(k,"id","module_utils/audio.RawAudio+data"),u(k,"class","group"),u(B,"id","module_utils/audio.RawAudio+toBlob"),u(B,"class","group"),u(j,"id","module_utils/audio.RawAudio+save"),u(j,"class","group"),u(N,"id","module_utils/audio.read_audio"),u(N,"class","group"),u(Q,"id","module_utils/audio.load_audio"),u(Q,"class","group"),u(te,"id","module_utils/audio.load_audio..audio"),u(te,"class","group"),u(le,"id","module_utils/audio.hanning"),u(le,"class","group"),u(ue,"id","module_utils/audio.hamming"),u(ue,"class","group"),u(fe,"id","module_utils/audio.mel_filter_bank"),u(fe,"class","group"),u(we,"id","module_utils/audio.spectrogram"),u(we,"class","group"),u(Le,"id","module_utils/audio.window_function"),u(Le,"class","group"),u(Re,"id","module_utils/audio..generalized_cosine_window"),u(Re,"class","group"),u(Be,"id","module_utils/audio..hertz_to_mel"),u(Be,"class","group"),u(je,"id","module_utils/audio..mel_to_hertz"),u(je,"class","group"),u(Oe,"id","module_utils/audio.._create_triangular_filter_bank"),u(Oe,"class","group"),u(Xe,"id","module_utils/audio..linspace"),u(Xe,"class","group"),u(dt,"id","module_utils/audio..padReflect"),u(dt,"class","group"),u(at,"id","module_utils/audio.._db_conversion_helper"),u(at,"class","group"),u(mt,"id","module_utils/audio..amplitude_to_db"),u(mt,"class","group"),u(bt,"id","module_utils/audio..power_to_db"),u(bt,"class","group"),u(xt,"id","module_utils/audio..encodeWAV"),u(xt,"class","group")},m(e,t){ca(document.head,g),o(e,kt,t),o(e,Pt,t),o(e,zt,t),o(e,w,t),o(e,Ft,t),p(v,e,t),o(e,Et,t),p(T,e,t),o(e,Bt,t),o(e,y,t),o(e,Dt,t),o(e,$,t),o(e,Kt,t),o(e,x,t),o(e,It,t),o(e,jt,t),o(e,St,t),o(e,H,t),o(e,Wt,t),p(A,e,t),o(e,Vt,t),o(e,L,t),o(e,Ot,t),o(e,M,t),o(e,Nt,t),o(e,Ut,t),o(e,Gt,t),o(e,C,t),o(e,Jt,t),p(q,e,t),o(e,Qt,t),o(e,P,t),o(e,Xt,t),o(e,R,t),o(e,Yt,t),o(e,Zt,t),o(e,ed,t),o(e,k,t),o(e,td,t),p(z,e,t),o(e,dd,t),o(e,F,t),o(e,od,t),o(e,E,t),o(e,ld,t),o(e,id,t),o(e,ad,t),o(e,B,t),o(e,rd,t),p(D,e,t),o(e,nd,t),o(e,K,t),o(e,ud,t),o(e,I,t),o(e,sd,t),o(e,md,t),o(e,cd,t),o(e,j,t),o(e,pd,t),p(S,e,t),o(e,fd,t),o(e,W,t),o(e,hd,t),o(e,V,t),o(e,_d,t),o(e,O,t),o(e,bd,t),o(e,gd,t),o(e,wd,t),o(e,N,t),o(e,vd,t),p(U,e,t),o(e,Td,t),o(e,G,t),o(e,yd,t),o(e,J,t),o(e,$d,t),o(e,xd,t),o(e,Hd,t),o(e,Q,t),o(e,Ad,t),p(X,e,t),o(e,Ld,t),o(e,Y,t),o(e,Md,t),o(e,Z,t),o(e,Cd,t),o(e,ee,t),o(e,qd,t),o(e,Pd,t),o(e,Rd,t),o(e,te,t),o(e,kd,t),p(de,e,t),o(e,zd,t),o(e,oe,t),o(e,Fd,t),o(e,Ed,t),o(e,Bd,t),o(e,le,t),o(e,Dd,t),p(ie,e,t),o(e,Kd,t),o(e,ae,t),o(e,Id,t),o(e,re,t),o(e,jd,t),o(e,ne,t),o(e,Sd,t),o(e,Wd,t),o(e,Vd,t),o(e,ue,t),o(e,Od,t),p(se,e,t),o(e,Nd,t),o(e,me,t),o(e,Ud,t),o(e,ce,t),o(e,Gd,t),o(e,pe,t),o(e,Jd,t),o(e,Qd,t),o(e,Xd,t),o(e,fe,t),o(e,Yd,t),p(he,e,t),o(e,Zd,t),o(e,_e,t),o(e,eo,t),o(e,be,t),o(e,to,t),o(e,ge,t),o(e,oo,t),o(e,lo,t),o(e,io,t),o(e,we,t),o(e,ao,t),p(ve,e,t),o(e,ro,t),o(e,Te,t),o(e,no,t),o(e,ye,t),o(e,uo,t),o(e,$e,t),o(e,so,t),o(e,xe,t),o(e,mo,t),o(e,He,t),o(e,co,t),o(e,Ae,t),o(e,po,t),o(e,fo,t),o(e,ho,t),o(e,Le,t),o(e,_o,t),p(Me,e,t),o(e,bo,t),o(e,Ce,t),o(e,go,t),o(e,qe,t),o(e,wo,t),o(e,Pe,t),o(e,vo,t),o(e,To,t),o(e,yo,t),o(e,Re,t),o(e,$o,t),p(ke,e,t),o(e,xo,t),o(e,ze,t),o(e,Ho,t),o(e,Fe,t),o(e,Ao,t),o(e,Ee,t),o(e,Lo,t),o(e,Mo,t),o(e,Co,t),o(e,Be,t),o(e,qo,t),p(De,e,t),o(e,Po,t),o(e,Ke,t),o(e,Ro,t),o(e,Ie,t),o(e,ko,t),o(e,zo,t),o(e,Fo,t),o(e,je,t),o(e,Eo,t),p(Se,e,t),o(e,Bo,t),o(e,We,t),o(e,Do,t),o(e,Ve,t),o(e,Ko,t),o(e,Io,t),o(e,jo,t),o(e,Oe,t),o(e,So,t),p(Ne,e,t),o(e,Wo,t),o(e,Ue,t),o(e,Vo,t),o(e,Ge,t),o(e,Oo,t),o(e,Je,t),o(e,No,t),o(e,Qe,t),o(e,Uo,t),o(e,Go,t),o(e,Jo,t),o(e,Xe,t),o(e,Qo,t),p(Ye,e,t),o(e,Xo,t),o(e,Ze,t),o(e,Yo,t),o(e,et,t),o(e,Zo,t),o(e,tt,t),o(e,el,t),o(e,tl,t),o(e,dl,t),o(e,dt,t),o(e,ol,t),p(ot,e,t),o(e,ll,t),o(e,lt,t),o(e,il,t),o(e,it,t),o(e,al,t),o(e,rl,t),o(e,nl,t),o(e,at,t),o(e,ul,t),p(rt,e,t),o(e,sl,t),o(e,nt,t),o(e,ml,t),o(e,ut,t),o(e,cl,t),o(e,st,t),o(e,pl,t),o(e,fl,t),o(e,hl,t),o(e,mt,t),o(e,_l,t),p(ct,e,t),o(e,bl,t),o(e,pt,t),o(e,gl,t),o(e,ft,t),o(e,wl,t),o(e,ht,t),o(e,vl,t),o(e,_t,t),o(e,Tl,t),o(e,yl,t),o(e,$l,t),o(e,bt,t),o(e,xl,t),p(gt,e,t),o(e,Hl,t),o(e,wt,t),o(e,Al,t),o(e,vt,t),o(e,Ll,t),o(e,Tt,t),o(e,Ml,t),o(e,yt,t),o(e,Cl,t),o(e,$t,t),o(e,ql,t),o(e,Pl,t),o(e,Rl,t),o(e,xt,t),o(e,kl,t),p(Ht,e,t),o(e,zl,t),o(e,At,t),o(e,Fl,t),o(e,Lt,t),o(e,El,t),o(e,Mt,t),o(e,Bl,t),o(e,Ct,t),o(e,Dl,t),o(e,Kl,t),o(e,Il,t),p(qt,e,t),o(e,jl,t),o(e,Rt,t),Sl=!0},p:ra,i(e){Sl||(f(v.$$.fragment,e),f(T.$$.fragment,e),f(A.$$.fragment,e),f(q.$$.fragment,e),f(z.$$.fragment,e),f(D.$$.fragment,e),f(S.$$.fragment,e),f(U.$$.fragment,e),f(X.$$.fragment,e),f(de.$$.fragment,e),f(ie.$$.fragment,e),f(se.$$.fragment,e),f(he.$$.fragment,e),f(ve.$$.fragment,e),f(Me.$$.fragment,e),f(ke.$$.fragment,e),f(De.$$.fragment,e),f(Se.$$.fragment,e),f(Ne.$$.fragment,e),f(Ye.$$.fragment,e),f(ot.$$.fragment,e),f(rt.$$.fragment,e),f(ct.$$.fragment,e),f(gt.$$.fragment,e),f(Ht.$$.fragment,e),f(qt.$$.fragment,e),Sl=!0)},o(e){h(v.$$.fragment,e),h(T.$$.fragment,e),h(A.$$.fragment,e),h(q.$$.fragment,e),h(z.$$.fragment,e),h(D.$$.fragment,e),h(S.$$.fragment,e),h(U.$$.fragment,e),h(X.$$.fragment,e),h(de.$$.fragment,e),h(ie.$$.fragment,e),h(se.$$.fragment,e),h(he.$$.fragment,e),h(ve.$$.fragment,e),h(Me.$$.fragment,e),h(ke.$$.fragment,e),h(De.$$.fragment,e),h(Se.$$.fragment,e),h(Ne.$$.fragment,e),h(Ye.$$.fragment,e),h(ot.$$.fragment,e),h(rt.$$.fragment,e),h(ct.$$.fragment,e),h(gt.$$.fragment,e),h(Ht.$$.fragment,e),h(qt.$$.fragment,e),Sl=!1},d(e){e&&(d(kt),d(Pt),d(zt),d(w),d(Ft),d(Et),d(Bt),d(y),d(Dt),d($),d(Kt),d(x),d(It),d(jt),d(St),d(H),d(Wt),d(Vt),d(L),d(Ot),d(M),d(Nt),d(Ut),d(Gt),d(C),d(Jt),d(Qt),d(P),d(Xt),d(R),d(Yt),d(Zt),d(ed),d(k),d(td),d(dd),d(F),d(od),d(E),d(ld),d(id),d(ad),d(B),d(rd),d(nd),d(K),d(ud),d(I),d(sd),d(md),d(cd),d(j),d(pd),d(fd),d(W),d(hd),d(V),d(_d),d(O),d(bd),d(gd),d(wd),d(N),d(vd),d(Td),d(G),d(yd),d(J),d($d),d(xd),d(Hd),d(Q),d(Ad),d(Ld),d(Y),d(Md),d(Z),d(Cd),d(ee),d(qd),d(Pd),d(Rd),d(te),d(kd),d(zd),d(oe),d(Fd),d(Ed),d(Bd),d(le),d(Dd),d(Kd),d(ae),d(Id),d(re),d(jd),d(ne),d(Sd),d(Wd),d(Vd),d(ue),d(Od),d(Nd),d(me),d(Ud),d(ce),d(Gd),d(pe),d(Jd),d(Qd),d(Xd),d(fe),d(Yd),d(Zd),d(_e),d(eo),d(be),d(to),d(ge),d(oo),d(lo),d(io),d(we),d(ao),d(ro),d(Te),d(no),d(ye),d(uo),d($e),d(so),d(xe),d(mo),d(He),d(co),d(Ae),d(po),d(fo),d(ho),d(Le),d(_o),d(bo),d(Ce),d(go),d(qe),d(wo),d(Pe),d(vo),d(To),d(yo),d(Re),d($o),d(xo),d(ze),d(Ho),d(Fe),d(Ao),d(Ee),d(Lo),d(Mo),d(Co),d(Be),d(qo),d(Po),d(Ke),d(Ro),d(Ie),d(ko),d(zo),d(Fo),d(je),d(Eo),d(Bo),d(We),d(Do),d(Ve),d(Ko),d(Io),d(jo),d(Oe),d(So),d(Wo),d(Ue),d(Vo),d(Ge),d(Oo),d(Je),d(No),d(Qe),d(Uo),d(Go),d(Jo),d(Xe),d(Qo),d(Xo),d(Ze),d(Yo),d(et),d(Zo),d(tt),d(el),d(tl),d(dl),d(dt),d(ol),d(ll),d(lt),d(il),d(it),d(al),d(rl),d(nl),d(at),d(ul),d(sl),d(nt),d(ml),d(ut),d(cl),d(st),d(pl),d(fl),d(hl),d(mt),d(_l),d(bl),d(pt),d(gl),d(ft),d(wl),d(ht),d(vl),d(_t),d(Tl),d(yl),d($l),d(bt),d(xl),d(Hl),d(wt),d(Al),d(vt),d(Ll),d(Tt),d(Ml),d(yt),d(Cl),d($t),d(ql),d(Pl),d(Rl),d(xt),d(kl),d(zl),d(At),d(Fl),d(Lt),d(El),d(Mt),d(Bl),d(Ct),d(Dl),d(Kl),d(Il),d(jl),d(Rt)),d(g),_(v,e),_(T,e),_(A,e),_(q,e),_(z,e),_(D,e),_(S,e),_(U,e),_(X,e),_(de,e),_(ie,e),_(se,e),_(he,e),_(ve,e),_(Me,e),_(ke,e),_(De,e),_(Se,e),_(Ne,e),_(Ye,e),_(ot,e),_(rt,e),_(ct,e),_(gt,e),_(Ht,e),_(qt,e)}}}const _a='{"title":"utils/audio","local":"utilsaudio","sections":[{"title":"utils/audio.RawAudio","local":"utilsaudiorawaudio","sections":[{"title":"new RawAudio(audio, sampling_rate)","local":"new-rawaudioaudio-samplingrate","sections":[],"depth":3},{"title":"rawAudio.data ⇒ Float32Array","local":"rawaudiodata--float32array","sections":[],"depth":3},{"title":"rawAudio.toBlob() ⇒ Blob","local":"rawaudiotoblob--blob","sections":[],"depth":3},{"title":"rawAudio.save(path) ⇒ Promise. < void >","local":"rawaudiosavepath--promise--void-","sections":[],"depth":3}],"depth":2},{"title":"<del> utils/audio.read_audio </del>","local":"del-utilsaudioreadaudio-del","sections":[],"depth":2},{"title":"utils/audio.load_audio(url, sampling_rate) ⇒ Promise. < Float32Array >","local":"utilsaudioloadaudiourl-samplingrate--promise--float32array-","sections":[{"title":"load_audio~audio : Float32Array","local":"loadaudioaudio--float32array","sections":[],"depth":3}],"depth":2},{"title":"utils/audio.hanning(M) ⇒ Float64Array","local":"utilsaudiohanningm--float64array","sections":[],"depth":2},{"title":"utils/audio.hamming(M) ⇒ Float64Array","local":"utilsaudiohammingm--float64array","sections":[],"depth":2},{"title":"utils/audio.mel_filter_bank(num_frequency_bins, num_mel_filters, min_frequency, max_frequency, sampling_rate, [norm], [mel_scale], [triangularize_in_mel_space]) ⇒ Array","local":"utilsaudiomelfilterbanknumfrequencybins-nummelfilters-minfrequency-maxfrequency-samplingrate-norm-melscale-triangularizeinmelspace--array","sections":[],"depth":2},{"title":"utils/audio.spectrogram(waveform, window, frame_length, hop_length, options) ⇒ Promise. < Tensor >","local":"utilsaudiospectrogramwaveform-window-framelength-hoplength-options--promise--tensor-","sections":[],"depth":2},{"title":"utils/audio.window_function(window_length, name, options) ⇒ Float64Array","local":"utilsaudiowindowfunctionwindowlength-name-options--float64array","sections":[],"depth":2},{"title":"utils/audio~generalized_cosine_window(M, a_0) ⇒ Float64Array","local":"utilsaudiogeneralizedcosinewindowm-a0--float64array","sections":[],"depth":2},{"title":"utils/audio~hertz_to_mel(freq, [mel_scale]) ⇒ T","local":"utilsaudiohertztomelfreq-melscale--t","sections":[],"depth":2},{"title":"utils/audio~mel_to_hertz(mels, [mel_scale]) ⇒ T","local":"utilsaudiomeltohertzmels-melscale--t","sections":[],"depth":2},{"title":"utils/audio~_create_triangular_filter_bank(fft_freqs, filter_freqs) ⇒ Array","local":"utilsaudiocreatetriangularfilterbankfftfreqs-filterfreqs--array","sections":[],"depth":2},{"title":"utils/audio~linspace(start, end, num) ⇒","local":"utilsaudiolinspacestart-end-num-","sections":[],"depth":2},{"title":"utils/audio~padReflect(array, left, right) ⇒ T","local":"utilsaudiopadreflectarray-left-right--t","sections":[],"depth":2},{"title":"utils/audio~_db_conversion_helper(spectrogram, factor, reference, min_value, db_range) ⇒ T","local":"utilsaudiodbconversionhelperspectrogram-factor-reference-minvalue-dbrange--t","sections":[],"depth":2},{"title":"utils/audio~amplitude_to_db(spectrogram, [reference], [min_value], [db_range]) ⇒ T","local":"utilsaudioamplitudetodbspectrogram-reference-minvalue-dbrange--t","sections":[],"depth":2},{"title":"utils/audio~power_to_db(spectrogram, [reference], [min_value], [db_range]) ⇒ T","local":"utilsaudiopowertodbspectrogram-reference-minvalue-dbrange--t","sections":[],"depth":2},{"title":"utils/audio~encodeWAV(chunks, rate) ⇒ Blob","local":"utilsaudioencodewavchunks-rate--blob","sections":[],"depth":2}],"depth":1}';function ba(Wl){return na(()=>{new URLSearchParams(window.location.search).get("fw")}),[]}class Ta extends ua{constructor(g){super(),sa(this,g,ba,ha,aa,{})}}export{Ta as component}; | |
Xet Storage Details
- Size:
- 57.3 kB
- Xet hash:
- b1d72cdcc2a2b2bea2fd27a88163e0aea431e354615352ba752afbe82cdd742d
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.