/sdf/group/fermi/u/kocevski/software/conda/envs/fermitools_v1.0.5/lib/python2.7/site-packages/pyfits/__init__.py:22: PyFITSDeprecationWarning: PyFITS is deprecated, please use astropy.io.fits
  PyFITSDeprecationWarning)  # noqa
 **********
 **   18 **HESSE 
 **********

 FCN=   6962.798     FROM HESSE     STATUS=OK           575 CALLS     3093 TOTAL
                     EDM=   .51E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .61016E-01    16.118        .11990E-01   -1.5703    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm           .0000        6.6974        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .45997E-06    21.019        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          14.056        3.1077        .26686E-03   -1.5633    
   5  norm          1.6329        1.1945        .82705E-03   -1.5682    
   6  Prefactor     .85176E-06    103.34        .84077E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor      .0000        33.599        .15378E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          2.0902        1.5439        .71366E-03   -1.5679    
   9  Prefactor     .27756E-08    20.365        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .24425E-08    8.5410        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .22403E-05    24.026        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .17619E-05    26.003        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .55511E-09    6.5818        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     37.852        26.460        .16232E-03   -1.5585    
  15  Prefactor     18.637        21.390        .23156E-03   -1.5622    
  16  norm          2.0614        7.6043        .72066E-03   -1.5679    
  17  Prefactor     3.6318        2.7947        .53019E-03   -1.5670    
  18  norm          1.1409        4.1697        .10965E-02   -1.5687    
  19  Prefactor     13.316        18.069        .27380E-03   -1.5635    
  20  Prefactor     .15914E-05    20.184        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .54012E-07    13.382        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm           .0000        .64703        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .93259E-08    9.7770        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          4.9435        5.1506        .45134E-03   -1.5663    
  25  Prefactor      .0000        3.2505        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          3.8609        1.9830        .51325E-03   -1.5669    
  27  Normalizat    1.1168        .14654        .37372E-01   -.89216    
  28  Prefactor     .78114        .18146        .70174E-01   -1.0043    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.05496e-07
Minuit parameter uncertainties:
  1  1.98342
  2  2.31261e-05
  3  0.00621873
  4  3.10766
  5  1.19452
  6  0.0187643
  7  2.97017e-05
  8  1.54393
  9  0.000476724
  10  0.00029
  11  0.0146733
  12  0.0135376
  13  0.000123196
  14  26.4604
  15  21.3905
  16  7.60437
  17  2.79473
  18  4.1697
  19  18.069
  20  0.0113351
  21  0.00170061
  22  1.81218e-06
  23  0.00060428
  24  5.15058
  25  1.76448e-05
  26  1.98295
  27  0.146589
  28  0.181598

Likelihood Analysis Tool
Support Contact: Daniel Kocevski (daniel.kocevski@nasa.gov)

Importing modules...
This is make3FGLxml version 01r0.
The default diffuse model files and names are for pass 8 and assume you have v10r00p05 of the Fermi Science Tools or higher.
This is make4FGLDR3xml version 01r09.
The default diffuse model files and names are for P8R3, 4FGL DRs, and the default fermitools directory locations.

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

/sdf/group/fermi/u/kocevski/software/conda/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/cbook/deprecation.py:106: MatplotlibDeprecationWarning: The mpl_toolkits.axes_grid module was deprecated in version 2.1. Use mpl_toolkits.axes_grid1 and mpl_toolkits.axisartist provies the same functionality instead.
  warnings.warn(message, mplDeprecation, stacklevel=1)

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 6962.79808544

Extracting fit parameters...

4FGL J1127.4+5648
   Spectrum: PowerLaw
386    Prefactor:  5.551e-10  1.232e-04  0.000e+00  1.000e+06 ( 1.000e-12)
387        Index:  2.718e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
388        Scale:  5.235e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
739    Prefactor:  7.811e-01  1.816e-01  0.000e+00  1.000e+01 ( 1.000e+00)
740        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
741        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
738   Normalization:  1.117e+00  1.466e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 171.865 56.803
Photon Flux Upper Limit: 7.04023900561e-08 ph cm-2 s-1
Energy Flux Upper Limit: 0.00554794841617 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/19652629/likelihoodResults_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6962.79699896
delta logL = 0.00108648193509

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6962.77595041
delta logL = 0.0221350274423

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .16493       1.0000          .0000       .10000E+07
     2 'Index     '    4.5205       1.0000          .0000       10.000    
     3 'Normalizat'    1.1058       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .78946       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7420E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6962.776     FROM MIGRAD    STATUS=CONVERGED     66 CALLS      274 TOTAL
                     EDM=   .40E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .16494        3.3160        .21311E-02** at limit **
   2  Index         4.5181        1.7805        .50000        .66274E-05
   3  Normalizat    1.1058        .96465E-02    .37767E-01    .61608E-04
   4  Prefactor     .78955        .12303E-01    .69841E-01    .34643E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.164942
  Index      = 4.51807
  Normalizat = 1.10579
  Prefactor  = 0.789546
 **********
 **   18 **HESSE 
 **********

 FCN=   6962.776     FROM HESSE     STATUS=NOT POSDEF    35 CALLS      309 TOTAL
                     EDM=   .44E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .16494        175.69        .11107E-03   -1.5700    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         4.5181        7.1767        .11158E-01   -.96536E-01
   3  Normalizat    1.1058        .13870        .20927E-03   -.89566    
   4  Prefactor     .78955        .13755        .30903E-03   -1.0011    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.41742e-06
Minuit parameter uncertainties:
  1  10.7666
  2  37.3258
  3  0.138745
  4  0.137609
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6962.77594988
delta logL = 0.0221355653703

Extracting fit parameters...

4FGL J1127.4+5648
   Spectrum: PowerLaw
386    Prefactor:  1.649e-01  1.077e+01  0.000e+00  1.000e+06 ( 1.000e-12)
387        Index:  4.518e+00  3.733e+01  0.000e+00  1.000e+01 (-1.000e+00)
388        Scale:  5.235e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
739    Prefactor:  7.895e-01  1.376e-01  0.000e+00  1.000e+01 ( 1.000e+00)
740        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
741        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
738   Normalization:  1.106e+00  1.387e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 171.865 56.803

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /lscratch/kocevski/19652629/cmap_HighResolution_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.55e-03', job_status='DONE', photon_flux_upper_limit='7.04e-08', time_completed='2023-07-18 00:48:55.599216', job_id='19652629', GAL2='0.79', fit_tolerance='1e-08', EG2='1.11', EG='1.12', time_epoch_completed='1689666535.6', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.78', dlogl='2.21e-02', ts2='0.05', photon_index_error='0.00', photon_index='2.72' WHERE bin_id='1820' AND source_name='4FGL J1127.4+5648' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Jul 18 00:48:55 PDT 2023

number of points = 7459
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1127.4+5648_daily_bin1820
RA = 171.865, Dec = 56.8032
tmin = 711072001, tmax = 711331201
emin = 100.0, emax = 100000.0
irfs = P8R3_SOURCE_V2
ROI = 12
zmax = 90

Fitting strategies:
Fix sources to their catalog values = True
Leave variable source normalizations free = True
Perform pre-fit where ALL sources are frozen to catalog values = False
Perform secondary fit with a free spectral index = True
Remove all catalog sources = False
Remove weak (TS < 2) catalog sources = False
Freeze Galactic component = False

Likelihood fit parameters:
Statistic: UNBINNED
Optimizer: MINUIT

Catalog: 4FGL

Repository job = True

LAT data source:
Data catalog

Updating database...

UPDATE lightcurve_data_v2 SET job_id='19653720', job_status='RUN', time_executed='2023-07-18 00:48:12.804414', time_epoch_executed='1689666492.8' WHERE source_name='4FGL J1127.4+5648' and cadence='daily' and bin_id='1820'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/19653720

Creating custom pfile directory:
/lscratch/kocevski/19653720/pfiles/

Retrieving the FT1 file...

Issuing command:
datacat find --group FT1 --filter 'nMetStop>=711072001.0 && nMetStart<711331201.0' /Data/Flight/Reprocess/P305

Issuing command:
datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=711072001.0 && nMetStart<711331201.0' /Data/Flight/Level1/LPA

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/19653720/ft1_4FGL_J1127.4+5648_daily_bin1820.fits


Retrieving the FT1 file...

Issuing command:
datacat find --group FT2 --filter 'nMetStop>=711072001.0 && nMetStart<711331201.0' /Data/Flight/Level1/LPA

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/19653720/ft1_4FGL_J1127.4+5648_daily_bin1820.fits outfile=/lscratch/kocevski/19653720/ft1_filteredMKT_4FGL_J1127.4+5648_daily_bin1820.fits ra=171.865 dec=56.8032 rad=12.0 tmin=711072001.0 tmax=711331201.0 emin=100.0 emax=100000.0 zmin=0.0 zmax=90.0 evclass=128 evtype="INDEF" convtype=-1 phasemin=0.0 phasemax=1.0 evtable="EVENTS" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Done.
real 2.44
user 1.79
sys 0.19

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/lscratch/kocevski/19653720/ft1_filteredMKT_4FGL_J1127.4+5648_daily_bin1820.fits evtable="EVENTS" outfile="/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits" apply_filter=yes overwrite=yes header_obstimes=yes tstart=0.0 tstop=0.0 gtifile="default" chatter=3 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtmktime version HEAD
Applying GTI filter:
IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.73
user 0.19
sys 0.13

Number of photons that the gtmktime cut: 647

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits" evtable="EVENTS" scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits sctable="SC_DATA" outfile=/lscratch/kocevski/19653720/ltcube_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits dcostheta=0.025 binsz=1.0 phibins=0 tmin=0.0 tmax=0.0 file_version="1" zmin=0.0 zmax=90.0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

Working on file /lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits
.....................!
real 8.16
user 7.63
sys 0.24

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits evtable="EVENTS" scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits sctable="SC_DATA" expcube=/lscratch/kocevski/19653720/ltcube_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits outfile=/lscratch/kocevski/19653720/expmap_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits irfs="P8R3_SOURCE_V2" evtype="INDEF" srcrad=30.0 nlong=88 nlat=88 nenergies=10 submap=no nlongmin=0 nlongmax=0 nlatmin=0 nlatmax=0 chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

The exposure maps generated by this tool are meant
to be used for *unbinned* likelihood analysis only.
Do not use them for binned analyses.
Computing the ExposureMap using /lscratch/kocevski/19653720/ltcube_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits
.....................!
real 67.44
user 62.72
sys 3.82

Generating the xml model:
radLim = 0.001
maxRad = 12
normsOnly = True
freeVariableSources = True
Fixing all sources to their catalog values, except variable sources
Creating file and adding sources from 4FGL
Added 233 point sources and 0 extended sources

Setting source of interest to:
4FGL J1127.4+5648 @ 171.865 56.8032

Creating the counts map:
time -p gtbin evfile=/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits outfile=/lscratch/kocevski/19653720/cmap_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=160 nypix=160 binsz=0.25 coordsys="CEL" xref=171.865 yref=56.8032 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 1.09
user 0.21
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits outfile=/lscratch/kocevski/19653720/cmap_HighResolution_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits algorithm="CMAP" ebinalg="LOG" emin=30.0 emax=200000.0 ebinfile=NONE tbinalg="LIN" tbinfile=NONE nxpix=500 nypix=500 binsz=0.1 coordsys="CEL" xref=171.865 yref=56.8032 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.74
user 0.20
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits evtable="EVENTS" scfile=/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/19653720/Model_4FGL_J1127.4+5648_daily_bin1820.xml irfs="P8R3_SOURCE_V2" evclsmin=0 evclass="INDEF" evtype="INDEF" convert=yes chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

adding source EG_v02
adding source GAL_V02
Working on...
/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits.....................!
real 26.09
user 24.02
sys 1.51

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits', '/lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits', expMap='/lscratch/kocevski/19653720/expmap_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits', expCube='/lscratch/kocevski/19653720/ltcube_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/19653720/Model_4FGL_J1127.4+5648_daily_bin1820.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1127.4+5648'

4FGL J1127.4+5648
   Spectrum: PowerLaw
386    Prefactor:  1.906e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-12)
387        Index:  2.718e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
388        Scale:  5.235e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /lscratch/kocevski/19653720/ft1_filtered_4FGL_J1127.4+5648_daily_bin1820.fits
Spacecraft file(s): /lscratch/kocevski/19653720/ft2_4FGL_J1127.4+5648_daily_bin1820.fits
Exposure map: /lscratch/kocevski/19653720/expmap_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits
Exposure cube: /lscratch/kocevski/19653720/ltcube_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/19653720/Model_4FGL_J1127.4+5648_daily_bin1820.xml
Optimizer: MINUIT
Statistic: UNBINNED

Performing an iterative likelihood fit...

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 6962.8196207

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 6962.80297828

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .18816       1.0000          .0000       .10000E+07
     2 'norm      '    .13104E-02   1.0000          .0000       .10000E+07
     3 'Prefactor '    .14487E-02   1.0000          .0000       .10000E+07
     4 'norm      '    14.060       1.0000          .0000       .10000E+07
     5 'norm      '    1.6330       1.0000          .0000       .10000E+07
     6 'Prefactor '    .44843       1.0000          .0000       .10000E+07
     7 'Prefactor '    .54166E-01   1.0000          .0000       .10000E+07
     8 'norm      '    2.0908       1.0000          .0000       .10000E+07
     9 'Prefactor '    .16668E-04   1.0000          .0000       .10000E+07
    10 'Prefactor '    .27931E-02   1.0000          .0000       .10000E+07
    11 'Prefactor '    .56434E-02   1.0000          .0000       .10000E+07
    12 'norm      '    .11381E-01   1.0000          .0000       .10000E+07
    13 'Prefactor '    .45884E-02   1.0000          .0000       .10000E+07
    14 'Prefactor '    37.964       1.0000          .0000       .10000E+07
    15 'Prefactor '    18.664       1.0000          .0000       .10000E+07
    16 'norm      '    2.0553       1.0000          .0000       .10000E+07
    17 'Prefactor '    3.6278       1.0000          .0000       .10000E+07
    18 'norm      '    1.1323       1.0000          .0000       .10000E+07
    19 'Prefactor '    13.358       1.0000          .0000       .10000E+07
    20 'Prefactor '    .97447E-03   1.0000          .0000       .10000E+07
    21 'Prefactor '    .11482E-01   1.0000          .0000       .10000E+07
    22 'norm      '    .51736E-07   1.0000          .0000       .10000E+07
    23 'Prefactor '    .84665E-02   1.0000          .0000       .10000E+07
    24 'norm      '    4.9600       1.0000          .0000       .10000E+07
    25 'Prefactor '    .61689E-04   1.0000          .0000       .10000E+07
    26 'norm      '    3.8621       1.0000          .0000       .10000E+07
    27 'Normalizat'    1.1163       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .78134       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7420E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6962.798     FROM MIGRAD    STATUS=CONVERGED    169 CALLS     2518 TOTAL
                     EDM=   .51E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .61016E-01    1205.5       -.87261E-05** at limit **
   2  norm           .0000        6.6784        .15028E-07** at limit **
   3  Prefactor     .45997E-06    6.5370        .16090E-06** at limit **
   4  norm          14.056        3.1017       -.17363E-07   -.40120E-02
   5  norm          1.6329        1.1955       -.56414E-09    .18220E-03
   6  Prefactor     .85176E-06    8.1768       -.78490E-07** at limit **
   7  Prefactor      .0000        33.613        .25239E-07** at limit **
   8  norm          2.0902        1.5382        .75520E-08    .14549E-02
   9  Prefactor     .27756E-08    7.1566        .55486E-07** at limit **
  10  Prefactor     .24425E-08    8.3747       -.30217E-06** at limit **
  11  Prefactor     .22403E-05    8.9255        .34911E-06** at limit **
  12  norm          .17619E-05    16.011       -.11525E-06** at limit **
  13  Prefactor     .55511E-09    6.5965        .64879E-07** at limit **
  14  Prefactor     37.852        1.2585       -.12118E-07    .73759E-02
  15  Prefactor     18.637        1.1929       -.67851E-09    .61741E-02
  16  norm          2.0614        7.5557       -.50248E-07   -.35623E-04
  17  Prefactor     3.6318        2.6661       -.21083E-07   -.15922E-02
  18  norm          1.1409        4.0424        .19677E-06    .29425E-02
  19  Prefactor     13.316        1.3580       -.24201E-07   -.61882E-02
  20  Prefactor     .15914E-05    8.0052       -.20847E-06** at limit **
  21  Prefactor     .54012E-07    13.067       -.43201E-07** at limit **
  22  norm           .0000        .65024        .64246E-08** at limit **
  23  Prefactor     .93259E-08    9.4947       -.16131E-06** at limit **
  24  norm          4.9435        5.1331        .20023E-08   -.52797E-04
  25  Prefactor      .0000        3.2566        .25973E-07** at limit **
  26  norm          3.8609        1.9811       -.10256E-07   -.16642E-02
  27  Normalizat    1.1168        .16623        .94027E-06    .12661E-03
  28  Prefactor     .78114        .20777       -.60911E-06    .57464E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0610161
  norm       = 0
  Prefactor  = 4.59965e-07
  norm       = 14.0562
  norm       = 1.63287
  Prefactor  = 8.51763e-07
  Prefactor  = 0
  norm       = 2.09023
  Prefactor  = 2.77556e-09
  Prefactor  = 2.44249e-09
  Prefactor  = 2.24032e-06
  norm       = 1.76192e-06
  Prefactor  = 5.55112e-10
  Prefactor  = 37.8515
  Prefactor  = 18.6372
  norm       = 2.06143
  Prefactor  = 3.63181
  norm       = 1.14092
  Prefactor  = 13.3164
  Prefactor  = 1.59139e-06
  Prefactor  = 5.40124e-08
  norm       = 0
  Prefactor  = 9.32587e-09
  norm       = 4.94354
  Prefactor  = 0
  norm       = 3.86088
  Normalizat = 1.11676
  Prefactor  = 0.781136
 **********
 **   18 **HESSE 
 **********

 FCN=   6962.798     FROM HESSE     STATUS=OK           575 CALLS     3093 TOTAL
                     EDM=   .51E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .61016E-01    16.118        .11990E-01   -1.5703    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm           .0000        6.6974        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .45997E-06    21.019        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          14.056        3.1077        .26686E-03   -1.5633    
   5  norm          1.6329        1.1945        .82705E-03   -1.5682    
   6  Prefactor     .85176E-06    103.34        .84077E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor      .0000        33.599        .15378E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          2.0902        1.5439        .71366E-03   -1.5679    
   9  Prefactor     .27756E-08    20.365        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .24425E-08    8.5410        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .22403E-05    24.026        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .17619E-05    26.003        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .55511E-09    6.5818        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     37.852        26.460        .16232E-03   -1.5585    
  15  Prefactor     18.637        21.390        .23156E-03   -1.5622    
  16  norm          2.0614        7.6043        .72066E-03   -1.5679    
  17  Prefactor     3.6318        2.7947        .53019E-03   -1.5670    
  18  norm          1.1409        4.1697        .10965E-02   -1.5687    
  19  Prefactor     13.316        18.069        .27380E-03   -1.5635    
  20  Prefactor     .15914E-05    20.184        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .54012E-07    13.382        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm           .0000        .64703        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .93259E-08    9.7770        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  norm          4.9435        5.1506        .45134E-03   -1.5663    
  25  Prefactor      .0000        3.2505        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  26  norm          3.8609        1.9830        .51325E-03   -1.5669    
  27  Normalizat    1.1168        .14654        .37372E-01   -.89216    
  28  Prefactor     .78114        .18146        .70174E-01   -1.0043    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.05496e-07
Minuit parameter uncertainties:
  1  1.98342
  2  2.31261e-05
  3  0.00621873
  4  3.10766
  5  1.19452
  6  0.0187643
  7  2.97017e-05
  8  1.54393
  9  0.000476724
  10  0.00029
  11  0.0146733
  12  0.0135376
  13  0.000123196
  14  26.4604
  15  21.3905
  16  7.60437
  17  2.79473
  18  4.1697
  19  18.069
  20  0.0113351
  21  0.00170061
  22  1.81218e-06
  23  0.00060428
  24  5.15058
  25  1.76448e-05
  26  1.98295
  27  0.146589
  28  0.181598
Done.

MINUIT Return Code (Fixed Index): 0
logL (Fixed Index) = 6962.79808544

Extracting fit parameters...

4FGL J1127.4+5648
   Spectrum: PowerLaw
386    Prefactor:  5.551e-10  1.232e-04  0.000e+00  1.000e+06 ( 1.000e-12)
387        Index:  2.718e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
388        Scale:  5.235e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
739    Prefactor:  7.811e-01  1.816e-01  0.000e+00  1.000e+01 ( 1.000e+00)
740        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
741        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
738   Normalization:  1.117e+00  1.466e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 171.865 56.803
Photon Flux Upper Limit: 7.04023900561e-08 ph cm-2 s-1
Energy Flux Upper Limit: 0.00554794841617 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/19653720/likelihoodResults_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.txt

Performing a free index iterative likelihood fit...

Freezing all point sources, except source of interest...

Done.

Freeing candidate source...
Done.

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 6962.79699896
delta logL = 0.00108648193509

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6962.77595041
delta logL = 0.0221350274423

Fit tolerance = 1e-08

Performing likelihood fit...
 **********
 **   14 **SET NOWARN 
 **********

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .16493       1.0000          .0000       .10000E+07
     2 'Index     '    4.5205       1.0000          .0000       10.000    
     3 'Normalizat'    1.1058       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .78946       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7420E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   6962.776     FROM MIGRAD    STATUS=CONVERGED     66 CALLS      274 TOTAL
                     EDM=   .40E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .16494        3.3160        .21311E-02** at limit **
   2  Index         4.5181        1.7805        .50000        .66274E-05
   3  Normalizat    1.1058        .96465E-02    .37767E-01    .61608E-04
   4  Prefactor     .78955        .12303E-01    .69841E-01    .34643E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.164942
  Index      = 4.51807
  Normalizat = 1.10579
  Prefactor  = 0.789546
 **********
 **   18 **HESSE 
 **********

 FCN=   6962.776     FROM HESSE     STATUS=NOT POSDEF    35 CALLS      309 TOTAL
                     EDM=   .44E-05    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .16494        175.69        .11107E-03   -1.5700    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         4.5181        7.1767        .11158E-01   -.96536E-01
   3  Normalizat    1.1058        .13870        .20927E-03   -.89566    
   4  Prefactor     .78955        .13755        .30903E-03   -1.0011    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.41742e-06
Minuit parameter uncertainties:
  1  10.7666
  2  37.3258
  3  0.138745
  4  0.137609
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6962.77594988
delta logL = 0.0221355653703

Extracting fit parameters...

4FGL J1127.4+5648
   Spectrum: PowerLaw
386    Prefactor:  1.649e-01  1.077e+01  0.000e+00  1.000e+06 ( 1.000e-12)
387        Index:  4.518e+00  3.733e+01  0.000e+00  1.000e+01 (-1.000e+00)
388        Scale:  5.235e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
739    Prefactor:  7.895e-01  1.376e-01  0.000e+00  1.000e+01 ( 1.000e+00)
740        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
741        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
738   Normalization:  1.106e+00  1.387e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 171.865 56.803

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /lscratch/kocevski/19653720/cmap_HighResolution_711072001_711331201_4FGL_J1127.4+5648_daily_bin1820.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.55e-03', job_status='DONE', photon_flux_upper_limit='7.04e-08', time_completed='2023-07-18 00:56:36.953699', job_id='19653720', GAL2='0.79', fit_tolerance='1e-08', EG2='1.11', EG='1.12', time_epoch_completed='1689666996.95', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.78', dlogl='2.21e-02', ts2='0.05', photon_index_error='0.00', photon_index='2.72' WHERE bin_id='1820' AND source_name='4FGL J1127.4+5648' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Jul 18 00:56:37 PDT 2023

