Repository navigation
Fourier upsampling in smooth_vel_fft for finer output grids - #52
Open
Nikhil0504 wants to merge 7 commits into
Open
Nikhil0504 wants to merge 7 commits into
Nikhil0504 wants to merge 7 commits into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Builds on #51.
smooth_vel_fftreturns the smoothed spectrum onoutwaveby linear interpolation. Whenoutwaveis finer than the input and the smoothed features are only a few pixels wide (a small velocity
dispersion on a barely sampled library), that interpolation changes the line profiles.
Changes
smooth_fft_upsample(dx, spec, sigma, upsample=1): the Gaussian taper ofsmooth_fft,returned
upsampletimes finer by zero padding in Fourier space (band-limited interpolation).upsample=1givessmooth_fftexactly.smooth_vel_fft: on a native log-uniform input (Smooth log-uniform spectra on their native samples in smooth_vel_fft #51), whenoutwaveis finer than the inputgrid, smooth with
upsample = ceil(input step / finest outwave step)before interpolating ontooutwave. Other cases are unchanged.Tests
smooth_fft_upsamplekeeps the input samples and equalssmooth_fftatupsample=1.0.05 A grid: within 2e-3 of the analytic result, while linear interpolation of the native
result is off by more than 5e-3. This test fails on Smooth log-uniform spectra on their native samples in smooth_vel_fft #51 alone.
Related: #32 (sinc convolution in pixel space).