GithubHelp home page GithubHelp logo

douglasleetucker / pyexcal Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 0.0 126 KB

A simple Python standard star fitter inspired by the SDSS mtpipe excal code.

License: GNU General Public License v3.0

Python 73.42% Shell 26.58%

pyexcal's Introduction

pyExcal

A Python standard star fitter inspired by the SDSS mtpipe excal code.

FAQ


How to run pyExcal?

  1. Ensure that you have the necessary dependencies installed on your computer:
    • Python 2.7 or higher
    • The numpy python module (pyExcal definitely works with numpy 1.11.1; other versions should work, too.)
    • The scipy python module (pyExcal definitely works with numpy 0.18.0; other versions should work, too.)
    A fairly recent version of Ureka (run "ur_setup") or astroconda should set up all the necessary versions of Python, numpy, and scipy.
  2. Run the appropriate setup script in the pyExcal bin directory, depending on which shell you are using (bash or tcsh):
     source pyExcal/bin/setup.bash
    or
     source pyExcal/bin/setup.csh
    **Note: you will need to modify the value for PYEXCAL_DIR in the setup script before the first time you ever run it.**
  3. Run the following command:
     pyExcal.py --inputFile $PYEXCAL_DIR/test/std-rguiz-test.g.csv --band g
You should get the following output to the screen, as well as two QA plots in png form:
bash$ pyExcal.py --inputFile $PYEXCAL_DIR/test/std-rguiz-test.g.csv --band g

Initial parameter values:   [1.6509999999999998, 0.0, 0.0]
Converged
Converged with chi squared  0.481103286398
degrees of freedom, dof  40
RMS of residuals (i.e. sqrt(chisq/dof))  0.109670334001
Reduced chisq (i.e. variance of residuals)  0.01202758216

Fitted parameters at minimum, with 68% C.I.:
a                1.34904 +/-     0.0629574   (4.666840 percent)
b            -0.00829816 +/-     0.0502757   (605.865115 percent)
k               0.214706 +/-     0.0391504   (18.234481 percent)

Correlation matrix:
                 a          b          k
a            1.000000
b           -0.101816   1.000000
k           -0.904639  -0.244643   1.000000


Your fit equation is:
    g_inst - g_std = 1.349 + -0.008*((g-r) - 0.530) + 0.215*X

Outputting QA plot qa-std-rguiz-test.g.csv_airmass.g-band.png
Outputting QA plot qa-std-rguiz-test.g.csv_color.g-band.png


That's all, folks!

The a, b, and k parameters are the familiar a, b, and k from the mtpipe photometric equations. Currently, I have ignored the "c" term coefficient (a.k.a., the second-order extinction), but that could be added if needed. (The concern is that it is so small that we won't get a significant fit for it, and will just end up adding noise to the fit.)

Back to top.


How to request updates to the code or to the FAQ?

Please use the issues to post requests for additions or other updates to the code or to this FAQ .

Back to top.

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.