GithubHelp home page GithubHelp logo

Comments (7)

weaverba137 avatar weaverba137 commented on July 21, 2024

@dkirkby, I'm assigning this to you so that you can assign it to someone who can actually resolve this.

from desimodel.

sbailey avatar sbailey commented on July 21, 2024

The difference between psf-quicksim and thru*.fits comes from the difference between what wavelengths all fibers see vs. the min/max that any fiber might see. psf-quicksim uses the range for fiber 100 which is a "typical" case in between. Quoting from a June 29, 2014 "Big desimodel update" email:

David K noted that the psf-quicksim.fits file doesn't have as much wavelength coverage as thru-?.fits files, and David S has asked about where to find out the min/max wavelength coverage since it isn't in desi.yaml anymore, so some explanation:

Due to the spectrograph optics, different fibers see a different wavelength ranges. Pat Jelinsky provides PSF spots and xy locations sampled at various wavelengths and slit positions (DESI-0334), but these do not correspond to specific fibers or to the exact edges of the CCDs. In desimodel/bin/spots2psf.py I fit these with Legendre polynomials and interpolate to specific fiber positions and calculate the wavelength coverage and put these in header keywords of the data/specpsf/psf-?.fits files:

WAVEMIN : smallest wavelength seen by any fiber
WAVEMAX : largest wavelength seen by any fiber
WMIN_ALL : smallest wavelength seen by all fibers
WMAX_ALL : largest wavelength seen by all fibers

These are rounded down(min) and up(max) to integer Angstroms. HDU 1 of the data/specpsf/psf-?.fits files contain the Legendre coefficients of the y vs. wavelength fits that can be used to determine the min/max wavelength range of an individual fiber.

bin/combine_throughputs.py combines system throughput (DESI-0347) with spectrograph throughput (DESI-0334) and outputs data/throughput/thru-?.fits, which covers WAVEMIN to WAVEMAX for each spectrograph arm. i.e. it covers the throughput range for all fibers, but any individual fiber will see a smaller wavelength range than that.

bin/psf2quicksim.py extracts PSF parameters needed for quicksim (FWHM, Neff) using fiber 100 as a "not the best but not the worst" case. It uses the ranges WMIN_ALL to WMAX_ALL, i.e. all fibers would see this wavelength range. quicksim should treat this as the wavelength range seen by the spectrograph arms, even though individual fibers will see slightly more. I think that is a better choice than tying quicksim to a specific fiber wavelength range.

i.e. the throughput files cover what might happen for some fiber, while the psf-quicksim file covers a typical range that should be used for the quick simulations, even though some fibers will see higher/lower wavelengths.

This has come up multiple times so better documentation could be in order, but I don't think it requires any code or data file changes.

from desimodel.

weaverba137 avatar weaverba137 commented on July 21, 2024

OK, so where exactly should the documentation go? In the data model for desimodel perhaps? Or in desimodel's own documentation?

from desimodel.

dkirkby avatar dkirkby commented on July 21, 2024

There is some explanation now in the DESI config file used by specsim:

# Specify the wavelength grid to use for simulation. For comparison, the
# table below summarizes the ranges of non-zero throughput in each camera,
# wavelengths that can disperse into CCDs (with a 5-sigma cut), and the
# extents of each CCD's active pixels covered by all fibers (as defined by
# cameras.*.ccd.table below). Note that individual fibers will generally have
# slightly more coverage, so we are simulating the worst-case coverage of
# all fibers.
#
#   Range     b(min)   b(max)   r(min)   r(max)   z(min)   z(max)
#            Angstrom Angstrom Angstrom Angstrom Angstrom Angstrom
# ---------- -------- -------- -------- -------- -------- --------
# Throughput 3533.000 5998.000 5564.000 7805.000 7360.000 9913.000
# Simulation 3550.000 ................................... 9850.000
#   Response 3565.400 5952.600 5621.700 7744.300 7431.000 9838.000
#        CCD 3569.000 5949.000 5625.000 7741.000 7435.000 9834.000
wavelength_grid:
    unit: Angstrom
    min: 3550.0
    max: 9850.0
    step: 0.1

from desimodel.

weaverba137 avatar weaverba137 commented on July 21, 2024

If this documentation is sufficient, I propose we close this.

from desimodel.

dkirkby avatar dkirkby commented on July 21, 2024

Ok with me.

from desimodel.

weaverba137 avatar weaverba137 commented on July 21, 2024

Closing.

from desimodel.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.