Emcee Fitting

I’ve changed the code to use emcee in order to fit the parameters of temperatures, flux ratio, and relative velocities of each targets visit spectrum individually.

In order to tell emcee when the parameters are a bad fit, I return the calculated chi2 value from the generated model. Emcee’s job is to minimize that calculated error.

A step by step process of this can be shown in the ipython notebook hosted here.

The current results are good for 2/3 targets that I have run against. The targets I used in my test sample are:

  • 2M03485329+3132297
  • 2M03405779+3118059
  • 2M03441568+3231282

The results are below (sorry for the screenshot but I was unable to upload the documents on WP).

screen-shot-2016-09-22-at-6-03-57-pm

screen-shot-2016-09-22-at-6-04-27-pm

screen-shot-2016-09-22-at-6-04-36-pm

The resulting parameters. (ignore Passes column, forgot to remove)

(ignore

Even the targets with a good chi2 value have the temperatures swapping every now and then and you can see to compensate for the ratio difference, the flux ratio goes above 1.0 to keep the secondary components flux ratio below the primary. I think these are cases of the initial guesses of the relative velocities were flipped for the primary and secondary.

What does seem odd though is only 2M03441568+3231282 has a consistent temperature of 3500 K. The program may need more time to run against these targets.

For the first target, 2M03405779+3118059, this target seems to require more time as well as it has with even more sporadic temperature values.

More passes may not be the answer though, as it currently takes 2 minutes per visit.

A possible approach to bring down the computation time, as it will be long, would be using multiple computers to run the software using SSH. The time it would save would be worth the time to implement it, but I’m not sure if we can use more.

 

EDIT: visit computation time.