/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/font_manager.py:281: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  'Matplotlib is building the font cache using fc-list. '
/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/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)


Waiting 222 seconds before starting...
Proceeding.

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

/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/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)

WARDone.


Performing analysis on: 4FGL_J0024.7+0349_daily_bin1778
RA = 6.1975, Dec = 3.8321
tmin = 700185601, tmax = 700444801
emin = 100.0, emax = 100000.0
irfs = P8R3_SOURCE_V2
ROI = 12
Done.


Performing analysis on: 4FGL_J0024.7+0349_daily_bin1778
RA = 6.1975, Dec = 3.8321
tmin = 700185601, tmax = 700444801
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='949372', job_status='RUN', time_executed='2023-03-14 00:10:50.355775', time_epoch_executed='1678777850.36' WHERE source_name='4FGL J0024.7+0349' and cadence='daily' and bin_id='1778'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/949372

Creating custom pfile directory:
/scratch/kocevski/949372/pfiles/

Retrieving the FT1 file...

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT1 --filter 'nMetStop>=700185601.0 && nMetStart<700444801.0' /Data/Flight/Reprocess/P305

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=700185601.0 && nMetStart<700444801.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/949372/ft1_4FGL_J0024.7+0349_daily_bin1778.fits


Retrieving the FT1 file...

Issuing command:
/afs/slac.stanford.edu/g/glast/ground/bin/datacat find --group FT2 --filter 'nMetStop>=700185601.0 && nMetStart<700444801.0' /Data/Flight/Level1/LPA

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/949372/ft1_4FGL_J0024.7+0349_daily_bin1778.fits outfile=/scratch/kocevski/949372/ft1_filteredMKT_4FGL_J0024.7+0349_daily_bin1778.fits ra=6.1975 dec=3.8321 rad=12.0 tmin=700185601.0 tmax=700444801.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 3.98
user 3.73
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/scratch/kocevski/949372/ft1_filteredMKT_4FGL_J0024.7+0349_daily_bin1778.fits evtable="EVENTS" outfile="/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.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('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/nfs/farm/g/glast/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.67
user 0.33
sys 0.16

Number of photons that the gtmktime cut: 582

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits" evtable="EVENTS" scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits sctable="SC_DATA" outfile=/scratch/kocevski/949372/ltcube_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.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 /scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits
.....................!
real 11.95
user 11.47
sys 0.41

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits evtable="EVENTS" scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits sctable="SC_DATA" expcube=/scratch/kocevski/949372/ltcube_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits outfile=/scratch/kocevski/949372/expmap_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.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 /scratch/kocevski/949372/ltcube_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits
.....................!
real 190.17
user 185.10
sys 4.56

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

Setting source of interest to:
4FGL J0024.7+0349 @ 6.1975 3.8321

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits outfile=/scratch/kocevski/949372/cmap_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.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=6.1975 yref=3.8321 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.54
user 0.38
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits outfile=/scratch/kocevski/949372/cmap_HighResolution_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.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=6.1975 yref=3.8321 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.54
user 0.38
sys 0.15

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits evtable="EVENTS" scfile=/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/949372/Model_4FGL_J0024.7+0349_daily_bin1778.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...
/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits.....................!
real 67.00
user 65.62
sys 1.16

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits', '/scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits', expMap='/scratch/kocevski/949372/expmap_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits', expCube='/scratch/kocevski/949372/ltcube_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/949372/Model_4FGL_J0024.7+0349_daily_bin1778.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0024.7+0349'

4FGL J0024.7+0349
   Spectrum: PowerLaw
118    Prefactor:  1.144e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-13)
119        Index:  2.391e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
120        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/949372/ft1_filtered_4FGL_J0024.7+0349_daily_bin1778.fits
Spacecraft file(s): /scratch/kocevski/949372/ft2_4FGL_J0024.7+0349_daily_bin1778.fits
Exposure map: /scratch/kocevski/949372/expmap_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits
Exposure cube: /scratch/kocevski/949372/ltcube_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/949372/Model_4FGL_J0024.7+0349_daily_bin1778.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) = 6344.08709588

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    22.413       1.0000          .0000       .10000E+07
     2 'Prefactor '    8.5187       1.0000          .0000       .10000E+07
     3 'norm      '    .83211E-06   1.0000          .0000       .10000E+07
     4 'Prefactor '    .13637E-02   1.0000          .0000       .10000E+07
     5 'norm      '    .13391E-04   1.0000          .0000       .10000E+07
     6 'norm      '    2.6842       1.0000          .0000       .10000E+07
     7 'Prefactor '    .72316E-04   1.0000          .0000       .10000E+07
     8 'norm      '    3.6845       1.0000          .0000       .10000E+07
     9 'norm      '    .90540       1.0000          .0000       .10000E+07
    10 'Prefactor '    .14036E-02   1.0000          .0000       .10000E+07
    11 'Prefactor '    .74263E-02   1.0000          .0000       .10000E+07
    12 'Prefactor '    3.8640       1.0000          .0000       .10000E+07
    13 'Prefactor '    7.4462       1.0000          .0000       .10000E+07
    14 'norm      '    .10576E-02   1.0000          .0000       .10000E+07
    15 'Prefactor '    119.61       1.0000          .0000       .10000E+07
    16 'norm      '    19.203       1.0000          .0000       .10000E+07
    17 'Prefactor '    .12966E-01   1.0000          .0000       .10000E+07
    18 'Prefactor '    .55262E-04   1.0000          .0000       .10000E+07
    19 'Normalizat'    .99855       1.0000         .10000E-01   10.000    
    20 'Prefactor '    1.1250       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5380E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6344.084     FROM MIGRAD    STATUS=CONVERGED    126 CALLS     1502 TOTAL
                     EDM=   .14E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     22.389        2.8413        .41094E-06    .99630E-02
   2  Prefactor     8.5021        6.8274       -.32968E-07    .16143E-02
   3  norm          .27756E-09    1.6533        .11400E-06** at limit **
   4  Prefactor     .12335E-06    14.527       -.37386E-05** at limit **
   5  norm           .0000        2.1254       -.30924E-06** at limit **
   6  norm          2.6839        3.2250        .22997E-06   -.82429E-02
   7  Prefactor      .0000        3.2089       -.36307E-07** at limit **
   8  norm          3.6810        8.8782       -.21029E-05   -.35010E-02
   9  norm          .91039        .54827       -.26764E-06   -.18080E-02
  10  Prefactor     .10103E-07    10.024        .40481E-05** at limit **
  11  Prefactor     .14433E-08    10.588        .82787E-06** at limit **
  12  Prefactor     3.8634        2.7356        .57179E-07    .45622E-02
  13  Prefactor     7.4487        4.9197        .94134E-09    .14100E-02
  14  norm          .28866E-08    4.8890       -.24798E-06** at limit **
  15  Prefactor     119.67        8.1992        .66488E-06   -.20645    
  16  norm          19.202        3.3874        .35335E-07    .97846E-02
  17  Prefactor     .54456E-07    21.948       -.32024E-05** at limit **
  18  Prefactor     .30831E-06    9.5915        .34449E-05** at limit **
  19  Normalizat    .99874        .24070       -.74836E-05   -.64340E-04
  20  Prefactor     1.1250        .17752        .44890E-05    .32181E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 22.3894
  Prefactor  = 8.50209
  norm       = 2.77556e-10
  Prefactor  = 1.23346e-07
  norm       = 0
  norm       = 2.68395
  Prefactor  = 0
  norm       = 3.68098
  norm       = 0.910392
  Prefactor  = 1.0103e-08
  Prefactor  = 1.44329e-09
  Prefactor  = 3.86338
  Prefactor  = 7.44869
  norm       = 2.88658e-09
  Prefactor  = 119.671
  norm       = 19.2018
  Prefactor  = 5.44564e-08
  Prefactor  = 3.08309e-07
  Normalizat = 0.998736
  Prefactor  = 1.12496
 **********
 **   18 **HESSE 
 **********

 FCN=   6344.084     FROM HESSE     STATUS=OK           329 CALLS     1831 TOTAL
                     EDM=   .36E-05    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     22.389        17.775        .21128E-03   -1.5613    
   2  Prefactor     8.5021        6.8204        .34322E-03   -1.5650    
   3  norm          .27756E-09    1.6383        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .12335E-06    15.334        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm           .0000        2.1277        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          2.6839        3.2379        .62166E-03   -1.5675    
   7  Prefactor      .0000        3.2058        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          3.6810        8.8913        .52593E-03   -1.5670    
   9  norm          .91039        16.176        .45388E-03   -1.5689    
  10  Prefactor     .10103E-07    19.989        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .14433E-08    10.450        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     3.8634        2.7361        .51312E-03   -1.5669    
  13  Prefactor     7.4487        4.9191        .36730E-03   -1.5653    
  14  norm          .28866E-08    4.9001        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     119.67        99.687        .91442E-04   -1.5489    
  16  norm          19.202        3.5343        .22828E-03   -1.5620    
  17  Prefactor     .54456E-07    22.544        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .30831E-06    17.443        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Normalizat    .99874        .21370        .71714E-01   -.93073    
  20  Prefactor     1.1250        .15636        .36706E-01   -.88673    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.64907e-06
Minuit parameter uncertainties:
  1  17.7754
  2  6.82036
  3  4.44564e-05
  4  0.00275066
  5  4.91821e-06
  6  3.23789
  7  3.99456e-06
  8  8.89134
  9  7.67501
  10  0.000899441
  11  0.000244791
  12  2.73611
  13  4.91911
  14  0.000238357
  15  99.6882
  16  3.53432
  17  0.00221607
  18  0.00463796
  19  0.213879
  20  0.156421
Done.

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

Extracting fit parameters...

4FGL J0024.7+0349
   Spectrum: PowerLaw
118    Prefactor:  0.000e+00  3.995e-06  0.000e+00  1.000e+06 ( 1.000e-13)
119        Index:  2.391e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
120        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
535    Prefactor:  1.125e+00  1.564e-01  0.000e+00  1.000e+01 ( 1.000e+00)
536        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
537        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
534   Normalization:  9.987e-01  2.139e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.00
Ra Dec: 6.197 3.832
Photon Flux Upper Limit: 5.99e-08 ph cm-2 s-1
Energy Flux Upper Limit: 4.63e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/949372/likelihoodResults_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.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): 102
logL (Free Index) = 6344.09082906
delta logL = -0.00647197129092

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6344.08435829
delta logL = -1.20068034448e-06

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.
  MNHESS FAILS AND WILL RETURN DIAGONAL MATRIX. 

 FCN=   6344.084     FROM MIGRAD    STATUS=CONVERGED     45 CALLS      224 TOTAL
                     EDM=   .15E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=100.0%

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor      .0000        2.7890        .42118E-03** at limit **
   2  Index         1.0380        .70265       -.35566E-04     .0000    
   3  Normalizat    .99874        1.3284        .44477E-04   -.29911E-04
   4  Prefactor     1.1250        1.1339       -.31789E-04    .23320E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0
  Index      = 1.03799
  Normalizat = 0.998738
  Prefactor  = 1.12496
 **********
 **   18 **HESSE 
 **********
  MNHESS FAILS AND WILL RETURN DIAGONAL MATRIX. 

 FCN=   6344.084     FROM HESSE     STATUS=FAILED         9 CALLS      233 TOTAL
                     EDM=   .15E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=100.0%

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor      .0000        2.7890        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         .53239E-01    1.0913       -.35566E-04   -.91474    
   3  Normalizat    .99874        1.3284        .44477E-04   -.93073    
   4  Prefactor     1.1250        1.1339       -.31789E-04   -.88673    
                               ERR DEF=  .500    
Minuit fit quality: 1   estimated distance: 1.47818e-10
Minuit parameter uncertainties:
  1  1.6211e-05
  2  0.709023
  3  1.37679
  4  1.15978
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/949372': No such file or directory
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
Done.

MINUIT Return Code (Free Index): 101
logL (Free Index) = 6344.08435709
delta logL = 1.38243194669e-10

Extracting fit parameters...

4FGL J0024.7+0349
   Spectrum: PowerLaw
118    Prefactor:  0.000e+00  1.621e-05  0.000e+00  1.000e+06 ( 1.000e-13)
119        Index:  1.038e+00  7.090e-01  0.000e+00  1.000e+01 (-1.000e+00)
120        Scale:  1.332e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
535    Prefactor:  1.125e+00  1.160e+00  0.000e+00  1.000e+01 ( 1.000e+00)
536        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
537        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
534   Normalization:  9.987e-01  1.377e+00  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.00
Ra Dec: 6.197 3.832

Creating a high resolution counts map...
INFO: Auto-setting vmin to  0.000e+00 [aplpy.core]
INFO: Auto-setting vmax to  0.000e+00 [aplpy.core]
Saving /scratch/kocevski/949372/cmap_HighResolution_700185601_700444801_4FGL_J0024.7+0349_daily_bin1778.png

Cleaning up...

** Nuclear option initiated! **
rmdir /scratch/kocevski/949372

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.63e-03', job_status='DONE', photon_flux_upper_limit='5.99e-08', time_completed='2023-03-14 00:20:00.434531', job_id='949372', GAL2='1.12', fit_tolerance='1e-08', EG2='1.00', EG='1.00', time_epoch_completed='1678778400.43', return_code2='101', ts='0.00', comment='SUCCESS', return_code='0', GAL='1.12', dlogl='1.38e-10', ts2='0.00', photon_index_error='0.00', photon_index='2.39' WHERE bin_id='1778' AND source_name='4FGL J0024.7+0349' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Mar 14 00:20:00 PDT 2023

J0024.7+0349_daily_bin1778> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Tue Mar 14 00:05:35 2023
Job was executed on host(s) <bullet0199>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Mar 14 00:05:36 2023
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Mar 14 00:05:36 2023
Terminated at Tue Mar 14 00:15:32 2023
Results reported at Tue Mar 14 00:15:32 2023

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0024.7+0349_daily_bin1778 6.1975 3.8321 700185601 700444801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0024.7+0349 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   554.00 sec.
    Max Memory :                                 617 MB
    Average Memory :                             293.32 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   595 sec.
    Turnaround time :                            597 sec.

The output (if any) is above this job summary.


------------------------------------------------------------
Sender: LSF System <lsf@bullet0134>
Subject: Job 949372: <4FGL_J0024.7+0349_daily_bin1778> in cluster <slac> Done

Job <4FGL_J0024.7+0349_daily_bin1778> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Tue Mar 14 00:05:35 2023
Job was executed on host(s) <bullet0134>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Mar 14 00:05:36 2023
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Mar 14 00:05:36 2023
Terminated at Tue Mar 14 00:20:01 2023
Results reported at Tue Mar 14 00:20:01 2023

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0024.7+0349_daily_bin1778 6.1975 3.8321 700185601 700444801 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0024.7+0349 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   549.20 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             250.48 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   864 sec.
    Turnaround time :                            866 sec.

The output (if any) is above this job summary.

