/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 2 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 make4FGLxml version 01r04.
The default diffuse model files and names are for pass 8 and 4FGL and assume you have v11r5p3 of the Fermi Science Tools or higher.

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)

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

number of points = 7678
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J0739.2+0137_daily_bin146
RA = 114.82, Dec = 1.6216
tmin = 277171201, tmax = 277430401
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='585957', job_status='RUN', time_executed='2021-08-27 20:05:42.985227', time_epoch_executed='1630119942.99' WHERE source_name='4FGL J0739.2+0137' and cadence='daily' and bin_id='146'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/585957

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

Retrieving the FT1 file...

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

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

Retrieving 49 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/585957/ft1_4FGL_J0739.2+0137_daily_bin146.fits


Retrieving the FT1 file...

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

Retrieving 49 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/585957/ft1_4FGL_J0739.2+0137_daily_bin146.fits outfile=/scratch/kocevski/585957/ft1_filteredMKT_4FGL_J0739.2+0137_daily_bin146.fits ra=114.82 dec=1.6216 rad=12.0 tmin=277171201.0 tmax=277430401.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.36
user 3.37
sys 0.94

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.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/585957/ft1_filteredMKT_4FGL_J0739.2+0137_daily_bin146.fits evtable="EVENTS" outfile="/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.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 1.27
user 0.33
sys 0.86

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits" evtable="EVENTS" scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits sctable="SC_DATA" outfile=/scratch/kocevski/585957/ltcube_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.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/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits
.....................!
real 12.61
user 11.40
sys 1.16

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits evtable="EVENTS" scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits sctable="SC_DATA" expcube=/scratch/kocevski/585957/ltcube_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits outfile=/scratch/kocevski/585957/expmap_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.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/585957/ltcube_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits
.....................!
real 190.51
user 185.02
sys 5.16

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
Extended source Rosette in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/Rosette.fits is the correct path to the extended template.
Extended source Monoceros in ROI with RadialGaussian spatial model.
Added 149 point sources and 2 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J0739.2+0137 @ 114.82 1.6216

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits outfile=/scratch/kocevski/585957/cmap_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.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=114.82 yref=1.6216 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.29
user 0.38
sys 0.87

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits outfile=/scratch/kocevski/585957/cmap_HighResolution_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.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=114.82 yref=1.6216 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.32
user 0.38
sys 0.86

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits evtable="EVENTS" scfile=/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/585957/Model_4FGL_J0739.2+0137_daily_bin146.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
adding source Monoceros
adding source Rosette
Working on...
/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits.....................!
real 141.60
user 139.05
sys 2.20

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits', '/scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits', expMap='/scratch/kocevski/585957/expmap_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits', expCube='/scratch/kocevski/585957/ltcube_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/585957/Model_4FGL_J0739.2+0137_daily_bin146.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0739.2+0137'

4FGL J0739.2+0137
   Spectrum: LogParabola
204         norm:  4.536e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-11)
205        alpha:  2.313e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
206         beta:  9.503e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
207           Eb:  4.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/585957/ft1_filtered_4FGL_J0739.2+0137_daily_bin146.fits
Spacecraft file(s): /scratch/kocevski/585957/ft2_4FGL_J0739.2+0137_daily_bin146.fits
Exposure map: /scratch/kocevski/585957/expmap_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits
Exposure cube: /scratch/kocevski/585957/ltcube_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/585957/Model_4FGL_J0739.2+0137_daily_bin146.xml
Optimizer: MINUIT
Statistic: UNBINNED

Performing an iterative likelihood fit...

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 102
logL (Fixed Index) = 8953.32732899

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    22.864       1.0000         .10000E-03   10000.    
     2 'norm      '    8.9022       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     4 'norm      '    8.5277       1.0000         .10000E-03   10000.    
     5 'norm      '    .17317       1.0000         .10000E-03   10000.    
     6 'Prefactor '    30.749       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    .10312E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    .10004E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    5.8537       1.0000         .10000E-03   10000.    
    14 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    5.7750       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10008E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10017E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    2.4366       1.0000         .10000E-03   10000.    
    20 'norm      '    6.9567       1.0000         .10000E-03   10000.    
    21 'norm      '    .10216E-03   1.0000         .10000E-03   10000.    
    22 'norm      '    .10003E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    6.6254       1.0000         .10000E-03   10000.    
    24 'Normalizat'    1.2383       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .95309       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5100E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   8953.300     FROM MIGRAD    STATUS=CONVERGED    567 CALLS     2475 TOTAL
                     EDM=   .60E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          22.863        14.174       -.30290E-06   -.47613E-04
   2  norm          8.9040        22.547        .19021E-05   -.30238E-04
   3  Prefactor     .10000E-03    14.384       -.96117E-05** at limit **
   4  norm          8.5284        7.3431       -.27880E-06   -.23253E-03
   5  norm          .15537        .88404        .10362E-05   -.17323E-02
   6  Prefactor     30.733        43.124       -.21326E-04   -.96671E-04
   7  Prefactor     .10000E-03    2.5138       -.30501E-06** at limit **
   8  Prefactor     .10000E-03    4.3877       -.82456E-06** at limit **
   9  Prefactor     .10000E-03    34.579       -.12109E-04** at limit **
  10  norm          .10000E-03    .85822        .24490E-06** at limit **
  11  Prefactor     .10000E-03    7.2945       -.82882E-06** at limit **
  12  norm          .10000E-03    11.361        .67860E-05** at limit **
  13  Prefactor     5.8536        3.9596        .38753E-06   -.20694E-03
  14  norm          .10000E-03    18.628       -.10574E-05** at limit **
  15  Prefactor     5.7760        10.445       -.32551E-06   -.93708E-04
  16  Prefactor     .10000E-03    2.5210        .11783E-06** at limit **
  17  Prefactor     .10000E-03    30.226        .12149E-04** at limit **
  18  norm          .10000E-03    5.4729        .62335E-07** at limit **
  19  norm          2.4365        2.6621       -.25848E-06   -.42689E-03
  20  norm          6.9567        2.4851        .41025E-07   -.60546E-04
  21  norm          .10000E-03    21.604        .12363E-04** at limit **
  22  norm          .10000E-03    1.5849        .72874E-07** at limit **
  23  Prefactor     6.6213        50.335       -.12549E-04   -.55945E-04
  24  Normalizat    1.2384        .20944        .12098E-05   -.38564E-03
  25  Prefactor     .95308        .72255E-01   -.25061E-07   -.59283E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 22.8629
  norm       = 8.90404
  Prefactor  = 0.0001
  norm       = 8.52841
  norm       = 0.155375
  Prefactor  = 30.7325
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 5.8536
  norm       = 0.0001
  Prefactor  = 5.77603
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 2.4365
  norm       = 6.95668
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 6.6213
  Normalizat = 1.23837
  Prefactor  = 0.953081
 **********
 **   18 **HESSE 
 **********

 FCN=   8953.300     FROM HESSE     STATUS=OK           423 CALLS     2898 TOTAL
                     EDM=   .60E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          22.863        14.264        .83770E-04   -1.4751    
   2  norm          8.9040        22.633        .13434E-03   -1.5111    
   3  Prefactor     .10000E-03    14.368        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  norm          8.5284        7.3832        .13727E-03   -1.5124    
   5  norm          .15537        6.0418        .16422E-02   -1.5629    
   6  Prefactor     30.733        43.162        .72256E-04   -1.4599    
   7  Prefactor     .10000E-03    2.5165        .14650E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    4.3912        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    34.616        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          .10000E-03    1.4379        .16847E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    7.2953        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          .10000E-03    11.417        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     5.8536        3.9704        .14732E-03   -1.5224    
  14  norm          .10000E-03    18.744        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     5.7760        10.444        .16713E-03   -1.5227    
  16  Prefactor     .10000E-03    2.5246        .14671E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    30.345        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    5.5335        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          2.4365        2.6508        .15382E-03   -1.5396    
  20  norm          6.9567        2.4820        .84824E-04   -1.5180    
  21  norm          .10000E-03    21.828        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  norm          .10000E-03    1.6054        .11631E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     6.6213        51.515        .15590E-03   -1.5193    
  24  Normalizat    1.2384        .22535        .39849E-03   -.85425    
  25  Prefactor     .95308        .79562E-01    .15670E-03   -.94310    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.03949e-09
Minuit parameter uncertainties:
  1  14.2657
  2  22.6545
  3  2.48276e-06
  4  7.38397
  5  1.93737
  6  43.2056
  7  3.94679e-06
  8  6.3405e-07
  9  6.1748e-05
  10  1.64301e-05
  11  4.52592e-07
  12  1.80315e-05
  13  3.97056
  14  6.22244e-07
  15  10.4475
  16  3.06513e-07
  17  1.02933e-05
  18  3.88575e-06
  19  2.65091
  20  2.48205
  21  4.02007e-05
  22  1.14291e-06
  23  36.9812
  24  0.225525
  25  0.079572
Done.

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

Extracting fit parameters...

4FGL J0739.2+0137
   Spectrum: LogParabola
204         norm:  1.000e-04  1.643e-05  1.000e-04  1.000e+04 ( 1.000e-11)
205        alpha:  2.313e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
206         beta:  9.503e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
207           Eb:  4.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
499    Prefactor:  9.531e-01  7.957e-02  0.000e+00  1.000e+01 ( 1.000e+00)
500        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
501        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
498   Normalization:  1.238e+00  2.255e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 114.820 1.622
Photon Flux Upper Limit: 9.12e-08 ph cm-2 s-1
Energy Flux Upper Limit: 2.95e-05 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/585957/likelihoodResults_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.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) = 8953.09990703
delta logL = 0.199652237539

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 8953.09989765
delta logL = 0.19966161167

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .30541       1.0000         .10000E-03   10000.    
     2 'alpha     '    3.9074       1.0000          .0000       5.0000    
     3 'Normalizat'    1.2008       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .95790       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5100E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   8953.100     FROM MIGRAD    STATUS=CONVERGED     51 CALLS      379 TOTAL
                     EDM=   .60E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .30381        13.523        .10449E-01    .41447E-02
   2  alpha         3.9107        2.6507        .50000        .65852E-04
   3  Normalizat    1.2008        .58245E-01    .91206E-01    .74518E-03
   4  Prefactor     .95789        .20061E-01    .45739E-01    .24709E-02
                               ERR DEF=  .500    
Final values: 
  norm       = 0.303806
  alpha      = 3.91073
  Normalizat = 1.20081
  Prefactor  = 0.957893
 **********
 **   18 **HESSE 
 **********

 FCN=   8953.100     FROM HESSE     STATUS=OK            27 CALLS      406 TOTAL
                     EDM=   .18E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .30381        .81485        .82606E-04   -1.5598    
   2  alpha         3.9107        1.5801        .50516E-02    .59958    
   3  Normalizat    1.2008        .21028        .40396E-03   -.86578    
   4  Prefactor     .95789        .71795E-01    .15635E-03   -.94147    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.78625e-09
Minuit parameter uncertainties:
  1  0.814885
  2  1.79965
  3  0.210428
  4  0.0718022
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/585957': 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): 0
logL (Free Index) = 8953.0998953
delta logL = 0.199663966567

Extracting fit parameters...

4FGL J0739.2+0137
   Spectrum: LogParabola
204         norm:  3.038e-01  8.149e-01  1.000e-04  1.000e+04 ( 1.000e-11)
205        alpha:  3.911e+00  1.800e+00  0.000e+00  5.000e+00 ( 1.000e+00)
206         beta:  9.503e-02  0.000e+00  0.000e+00  1.000e+01 ( 1.000e+00) fixed
207           Eb:  4.724e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
499    Prefactor:  9.579e-01  7.180e-02  0.000e+00  1.000e+01 ( 1.000e+00)
500        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
501        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
498   Normalization:  1.201e+00  2.104e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 114.820 1.622

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 /scratch/kocevski/585957/cmap_HighResolution_277171201_277430401_4FGL_J0739.2+0137_daily_bin146.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.95e-05', job_status='DONE', photon_flux_upper_limit='9.12e-08', time_completed='2021-08-27 20:19:55.782930', job_id='585957', GAL2='0.96', fit_tolerance='1e-08', EG2='1.20', EG='1.24', time_epoch_completed='1630120795.78', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.95', dlogl='2.00e-01', ts2='0.43', photon_index_error='0.00', photon_index='2.31' WHERE bin_id='146' AND source_name='4FGL J0739.2+0137' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Aug 27 20:19:55 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0226>
Subject: Job 585957: <4FGL_J0739.2+0137_daily_bin146> in cluster <slac> Done

Job <4FGL_J0739.2+0137_daily_bin146> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Fri Aug 27 20:05:17 2021
Job was executed on host(s) <bullet0226>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Aug 27 20:05:19 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Fri Aug 27 20:05:19 2021
Terminated at Fri Aug 27 20:19:56 2021
Results reported at Fri Aug 27 20:19:56 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0739.2+0137_daily_bin146 114.82 1.6216 277171201 277430401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0739.2+0137 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   860.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             363.18 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   877 sec.
    Turnaround time :                            879 sec.

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

