/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

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).

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


Performing analysis on: 4FGL_J1542.3+1801_weekly_bin907
RA = 235.579, Dec = 18.0322
tmin = 787536001, tmax = 788140801
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='17775002', job_status='RUN', time_executed='2025-12-23 02:00:19.731533', time_epoch_executed='1766484019.73' WHERE source_name='4FGL J1542.3+1801' and cadence='weekly' and bin_id='907'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/17775002

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

Retrieving the FT1 file...

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

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

Retrieving 108 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/17775002/ft1_4FGL_J1542.3+1801_weekly_bin907.fits


Retrieving the FT1 file...

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

Retrieving 108 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/17775002/ft1_4FGL_J1542.3+1801_weekly_bin907.fits outfile=/lscratch/kocevski/17775002/ft1_filteredMKT_4FGL_J1542.3+1801_weekly_bin907.fits ra=235.579 dec=18.0322 rad=12.0 tmin=787536001.0 tmax=788140801.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 4.93
user 4.20
sys 0.23

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.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/17775002/ft1_filteredMKT_4FGL_J1542.3+1801_weekly_bin907.fits evtable="EVENTS" outfile="/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.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.82
user 0.21
sys 0.14

Number of photons that the gtmktime cut: 1725

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits" evtable="EVENTS" scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits sctable="SC_DATA" outfile=/lscratch/kocevski/17775002/ltcube_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.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/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits
.....................!
real 19.75
user 18.64
sys 0.38

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits evtable="EVENTS" scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits sctable="SC_DATA" expcube=/lscratch/kocevski/17775002/ltcube_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits outfile=/lscratch/kocevski/17775002/expmap_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.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/17775002/ltcube_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits
.....................!
real 68.67
user 63.62
sys 4.08

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 155 point sources and 0 extended sources

Setting source of interest to:
4FGL J1542.3+1801 @ 235.579 18.0322

Creating the counts map:
time -p gtbin evfile=/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits outfile=/lscratch/kocevski/17775002/cmap_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.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=235.579 yref=18.0322 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.67
user 0.22
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits outfile=/lscratch/kocevski/17775002/cmap_HighResolution_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.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=235.579 yref=18.0322 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.71
user 0.23
sys 0.13

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits evtable="EVENTS" scfile=/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/17775002/Model_4FGL_J1542.3+1801_weekly_bin907.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/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits.....................!
real 49.43
user 47.35
sys 1.44

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits', '/lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits', expMap='/lscratch/kocevski/17775002/expmap_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits', expCube='/lscratch/kocevski/17775002/ltcube_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/17775002/Model_4FGL_J1542.3+1801_weekly_bin907.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1542.3+1801'

4FGL J1542.3+1801
   Spectrum: PowerLaw
238    Prefactor:  4.061e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-13)
239        Index:  2.522e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
240        Scale:  8.483e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /lscratch/kocevski/17775002/ft1_filtered_4FGL_J1542.3+1801_weekly_bin907.fits
Spacecraft file(s): /lscratch/kocevski/17775002/ft2_4FGL_J1542.3+1801_weekly_bin907.fits
Exposure map: /lscratch/kocevski/17775002/expmap_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits
Exposure cube: /lscratch/kocevski/17775002/ltcube_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/17775002/Model_4FGL_J1542.3+1801_weekly_bin907.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) = 18368.8979194

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    37.601       1.0000          .0000       .10000E+07
     2 'Prefactor '    .16692E-06   1.0000          .0000       .10000E+07
     3 'norm      '    .64780E-01   1.0000          .0000       .10000E+07
     4 'norm      '    .49476E-02   1.0000          .0000       .10000E+07
     5 'Prefactor '    .10748E-02   1.0000          .0000       .10000E+07
     6 'Prefactor '    .25512       1.0000          .0000       .10000E+07
     7 'Prefactor '    25.119       1.0000          .0000       .10000E+07
     8 'norm      '    2.6851       1.0000          .0000       .10000E+07
     9 'Prefactor '    .10558E-01   1.0000          .0000       .10000E+07
    10 'norm      '    5.2267       1.0000          .0000       .10000E+07
    11 'norm      '    4.4197       1.0000          .0000       .10000E+07
    12 'Prefactor '    3.3467       1.0000          .0000       .10000E+07
    13 'norm      '    122.57       1.0000          .0000       .10000E+07
    14 'Prefactor '    .22667E-03   1.0000          .0000       .10000E+07
    15 'Normalizat'    1.1589       1.0000         .10000E-01   10.000    
    16 'Prefactor '    .89097       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5030E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   18368.89     FROM MIGRAD    STATUS=CONVERGED     86 CALLS     1089 TOTAL
                     EDM=   .12E-10  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.8%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     37.738        1.0878       -.18778E-09    .97075E-02
   2  Prefactor      .0000        1.4638       -.21639E-06** at limit **
   3  norm          .64815E-01    .10467       -.51590E-07** at limit **
   4  norm           .0000        7.7895        .25052E-07** at limit **
   5  Prefactor      .0000        20.250        .12457E-07** at limit **
   6  Prefactor     .25480        .58116        .12781E-06    .61616E-03
   7  Prefactor     25.091        1.1669       -.67463E-09    .56589E-02
   8  norm          2.6817        1.6328        .68606E-07   -.97215E-03
   9  Prefactor      .0000        13.938        .12258E-06** at limit **
  10  norm          5.2981        5.2692       -.25274E-06    .67049E-03
  11  norm          4.4179        1.1793        .61576E-07   -.85420E-03
  12  Prefactor     3.3474        3.1343       -.14220E-06   -.21777E-03
  13  norm          122.57        1.0242       -.84354E-09   -.16149E-01
  14  Prefactor      .0000        5.2704        .19902E-06** at limit **
  15  Normalizat    1.1588        .15831       -.49342E-06   -.19456E-04
  16  Prefactor     .89091        .89413E-01    .21069E-05   -.77658E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 37.7381
  Prefactor  = 0
  norm       = 0.0648149
  norm       = 0
  Prefactor  = 0
  Prefactor  = 0.254803
  Prefactor  = 25.091
  norm       = 2.68168
  Prefactor  = 0
  norm       = 5.29814
  norm       = 4.41795
  Prefactor  = 3.34738
  norm       = 122.567
  Prefactor  = 0
  Normalizat = 1.15882
  Prefactor  = 0.890914
 **********
 **   18 **HESSE 
 **********

 FCN=   18368.89     FROM HESSE     STATUS=OK           239 CALLS     1328 TOTAL
                     EDM=   .71E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     37.738        21.782        .16310E-03   -1.5585    
   2  Prefactor      .0000        1.4640        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .64815E-01    .10456        .12259E-02   -1.5703    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm           .0000        7.7881        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor      .0000        20.277        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .25480        .57968        .37876E-02   -1.5698    
   7  Prefactor     25.091        21.105        .19957E-03   -1.5608    
   8  norm          2.6817        1.6440        .62154E-03   -1.5675    
   9  Prefactor      .0000        13.962        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          5.2981        5.3176        .43944E-03   -1.5662    
  11  norm          4.4179        1.1801        .47878E-03   -1.5666    
  12  Prefactor     3.3474        3.1334        .55298E-03   -1.5671    
  13  norm          122.57        16.277        .90332E-04   -1.5487    
  14  Prefactor      .0000        5.2598        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Normalizat    1.1588        .13403        .69255E-01   -.87885    
  16  Prefactor     .89091        .73685E-01    .44890E-01   -.96459    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.10565e-09
Minuit parameter uncertainties:
  1  21.7818
  2  3.3282e-06
  3  0.104563
  4  5.52675e-06
  5  1.62213e-05
  6  0.57968
  7  21.1053
  8  1.64398
  9  3.12811e-06
  10  5.31759
  11  1.18011
  12  3.1334
  13  16.2773
  14  1.04049e-06
  15  0.134074
  16  0.0736928
Done.

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

Extracting fit parameters...

4FGL J1542.3+1801
   Spectrum: PowerLaw
238    Prefactor:  2.509e+01  2.111e+01  0.000e+00  1.000e+06 ( 1.000e-13)
239        Index:  2.522e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
240        Scale:  8.483e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
500    Prefactor:  8.909e-01  7.369e-02  0.000e+00  1.000e+01 ( 1.000e+00)
501        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
502        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
499   Normalization:  1.159e+00  1.341e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 1.78
Ra Dec: 235.579 18.032
Photon Index (Fixed Index): 2.52 +/- 0.00
Photon Flux (Fixed Index): 3.63e-08 +/- 3.05e-08
Energy Flux (Fixed Index): 1.03e-05 +/- 8.64e-06

TS (Fixed Index): 1.78
Ra Dec: 235.579 18.032
Photon Flux Upper Limit: 9.49853981489e-08 ph cm-2 s-1
Energy Flux Upper Limit: 0.00739818959642 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/17775002/likelihoodResults_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.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) = 18368.5948679
delta logL = 0.299399203155

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 18368.5532654
delta logL = 0.341001744036

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
 MACHINE ACCURACY LIMITS FURTHER IMPROVEMENT.

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
 MIGRAD TERMINATED WITHOUT CONVERGENCE.

 FCN=   18368.55     FROM MIGRAD    STATUS=FAILED       102 CALLS      295 TOTAL
                     EDM=   .15E-06    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     14.066        32.840        .10662E-04   -.24268E-02
   2  Index         3.1164        1.3673        .86071E-02    .12096E-02
   3  Normalizat    1.1354        .16362        .30913E-03   -.20345E-03
   4  Prefactor     .89982        .90912E-01    .19258E-03   -.26706E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   18368.55     FROM SIMPLEX   STATUS=UNCHANGED     76 CALLS      371 TOTAL
                     EDM=   .90E-05    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     14.066        32.840        .27040E-04   -1.5633    
   2  Index         3.1164        1.3673        .84990E-03   -.38625    
   3  Normalizat    1.1354        .16362        .23027E-03   -.88623    
   4  Prefactor     .89982        .90912E-01    .13553E-03   -.96147    
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   18368.55     FROM MIGRAD    STATUS=CONVERGED     29 CALLS      400 TOTAL
                     EDM=   .18E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     14.066        20.892        .42648E-06   -.12982E-02
   2  Index         3.1164        .87645        .17214E-02   -.21107E-04
   3  Normalizat    1.1354        .16258        .12365E-04   -.76495E-04
   4  Prefactor     .89982        .90083E-01    .77033E-05   -.99175E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 14.066
  Index      = 3.11641
  Normalizat = 1.1354
  Prefactor  = 0.899819
 **********
 **   18 **HESSE 
 **********

 FCN=   18368.55     FROM HESSE     STATUS=OK            23 CALLS      423 TOTAL
                     EDM=   .15E-10    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     14.066        19.698        .37272E-06   -1.5633    
   2  Index         3.1164        .82625        .68857E-04   -.38625    
   3  Normalizat    1.1354        .16233        .24730E-05   -.88623    
   4  Prefactor     .89982        .89912E-01    .15407E-05   -.96147    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.51737e-11
Minuit parameter uncertainties:
  1  19.6981
  2  0.830701
  3  0.162398
  4  0.0899268
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 18368.5532593
delta logL = 0.34100782773

Extracting fit parameters...

4FGL J1542.3+1801
   Spectrum: PowerLaw
238    Prefactor:  1.407e+01  1.970e+01  0.000e+00  1.000e+06 ( 1.000e-13)
239        Index:  3.116e+00  8.307e-01  0.000e+00  1.000e+01 (-1.000e+00)
240        Scale:  8.483e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
500    Prefactor:  8.998e-01  8.993e-02  0.000e+00  1.000e+01 ( 1.000e+00)
501        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
502        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
499   Normalization:  1.135e+00  1.624e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.50
Ra Dec: 235.579 18.032
Photon Index (Free Index): 3.12 +/- 0.83
Photon Flux (Free Index): 5.21e-08 +/- 3.82e-08
Energy Flux (Free Index): 9.86e-06 +/- 7.23e-06

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/17775002/cmap_HighResolution_787536001_788140801_4FGL_J1542.3+1801_weekly_bin907.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.40e-03', comment='SUCCESS', photon_flux='3.63e-08', energy_flux2='9.86e-06', photon_flux_error='3.05e-08', dlogl='3.41e-01', energy_flux='1.03e-05', photon_flux2='5.21e-08', job_status='DONE', time_completed='2025-12-23 02:13:29.760613', photon_index_error2='0.83', photon_index2='3.12', ts='1.78', fit_tolerance='1e-08', GAL='0.89', photon_index_error='0.00', photon_flux_upper_limit='9.50e-08', energy_flux_error2='7.23e-06', EG='1.16', time_epoch_completed='1766484809.76', return_code='0', job_id='17775002', GAL2='0.90', EG2='1.14', return_code2='0', energy_flux_error='8.64e-06', photon_flux_error2='3.82e-08', ts2='2.50', photon_index='2.52' WHERE bin_id='907' AND source_name='4FGL J1542.3+1801' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Tue Dec 23 02:13:30 PST 2025

