/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 7 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 = 7463
number of fields = 29
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J0739.2+0137_daily_bin521
RA = 114.82, Dec = 1.6216
tmin = 374371201, tmax = 374630401
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='587833', job_status='RUN', time_executed='2021-08-27 20:12:22.872846', time_epoch_executed='1630120342.87' WHERE source_name='4FGL J0739.2+0137' and cadence='daily' and bin_id='521'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/587833

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

Retrieving the FT1 file...

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

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

Retrieving 43 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/587833/ft1_4FGL_J0739.2+0137_daily_bin521.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/587833/ft1_4FGL_J0739.2+0137_daily_bin521.fits outfile=/scratch/kocevski/587833/ft1_filteredMKT_4FGL_J0739.2+0137_daily_bin521.fits ra=114.82 dec=1.6216 rad=12.0 tmin=374371201.0 tmax=374630401.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 7.51
user 2.99
sys 4.47

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.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/587833/ft1_filteredMKT_4FGL_J0739.2+0137_daily_bin521.fits evtable="EVENTS" outfile="/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.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 4.87
user 0.34
sys 4.50

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits" evtable="EVENTS" scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits sctable="SC_DATA" outfile=/scratch/kocevski/587833/ltcube_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.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/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits
.....................!
real 17.08
user 11.81
sys 5.20

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits evtable="EVENTS" scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits sctable="SC_DATA" expcube=/scratch/kocevski/587833/ltcube_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits outfile=/scratch/kocevski/587833/expmap_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.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/587833/ltcube_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits
.....................!
real 196.00
user 185.39
sys 10.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
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/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits outfile=/scratch/kocevski/587833/cmap_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.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 4.79
user 0.38
sys 4.38

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits outfile=/scratch/kocevski/587833/cmap_HighResolution_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.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 5.03
user 0.40
sys 4.40

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits evtable="EVENTS" scfile=/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/587833/Model_4FGL_J0739.2+0137_daily_bin521.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/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits.....................!
real 124.45
user 117.14
sys 6.84

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits', '/scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits', expMap='/scratch/kocevski/587833/expmap_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits', expCube='/scratch/kocevski/587833/ltcube_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/587833/Model_4FGL_J0739.2+0137_daily_bin521.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/587833/ft1_filtered_4FGL_J0739.2+0137_daily_bin521.fits
Spacecraft file(s): /scratch/kocevski/587833/ft2_4FGL_J0739.2+0137_daily_bin521.fits
Exposure map: /scratch/kocevski/587833/expmap_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits
Exposure cube: /scratch/kocevski/587833/ltcube_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/587833/Model_4FGL_J0739.2+0137_daily_bin521.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) = 8100.49702368

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    17.973       1.0000         .10000E-03   10000.    
     3 'Prefactor '    39.339       1.0000         .10000E-03   10000.    
     4 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    .10058E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .16047       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    19.780       1.0000         .10000E-03   10000.    
    10 'norm      '    .13068E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    20.756       1.0000         .10000E-03   10000.    
    12 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10019E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    18.395       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10010E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10012E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    3.8300       1.0000         .10000E-03   10000.    
    20 'norm      '    .15266       1.0000         .10000E-03   10000.    
    21 'norm      '    11.891       1.0000         .10000E-03   10000.    
    22 'norm      '    .10390E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .74103       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .96525       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=   8100.492     FROM MIGRAD    STATUS=CONVERGED    586 CALLS     2962 TOTAL
                     EDM=   .23E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    4.0880       -.73631E-06** at limit **
   2  norm          17.973        17.065       -.15402E-06   -.18848E-04
   3  Prefactor     39.336        47.741       -.32027E-05   -.60982E-04
   4  norm          .10000E-03    4.2339        .12014E-05** at limit **
   5  norm          .10000E-03    .60443        .14460E-07** at limit **
   6  Prefactor     .10000E-03    11.577        .11502E-05** at limit **
   7  Prefactor     .13878        4.3696       -.22926E-06    .15119E-04
   8  Prefactor     .10000E-03    4.7054       -.54233E-06** at limit **
   9  Prefactor     19.779        30.341        .23827E-06    .21102E-04
  10  norm          .10000E-03    .63416       -.86398E-07** at limit **
  11  Prefactor     20.756        19.891        .67406E-07    .14421E-04
  12  norm          .10000E-03    11.523        .95711E-06** at limit **
  13  Prefactor     .10000E-03    .88693        .14744E-08** at limit **
  14  norm          .10000E-03    7.1186       -.52941E-06** at limit **
  15  Prefactor     18.393        11.527        .17508E-07    .16282E-04
  16  Prefactor     .10000E-03    10.837       -.84855E-06** at limit **
  17  Prefactor     .10000E-03    9.6646       -.14837E-05** at limit **
  18  norm          .10000E-03    8.4371        .51698E-06** at limit **
  19  norm          3.8296        1.8862        .29523E-06   -.21919E-02
  20  norm          .15206        .90020       -.20929E-06   -.55333E-04
  21  norm          11.888        15.650       -.11155E-05   -.60204E-04
  22  norm          .10000E-03    1.7935        .51163E-07** at limit **
  23  Prefactor     .10000E-03    7.8087        .10863E-05** at limit **
  24  Normalizat    .74114        .18350        .27451E-06    .42533E-04
  25  Prefactor     .96525        .65328E-01    .50885E-07    .65325E-04
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  norm       = 17.9729
  Prefactor  = 39.3356
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.138783
  Prefactor  = 0.0001
  Prefactor  = 19.7793
  norm       = 0.000100003
  Prefactor  = 20.7561
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 18.3934
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 3.82959
  norm       = 0.152055
  norm       = 11.8876
  norm       = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.741139
  Prefactor  = 0.965254
 **********
 **   18 **HESSE 
 **********

 FCN=   8100.492     FROM HESSE     STATUS=OK           431 CALLS     3393 TOTAL
                     EDM=   .35E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    4.1242        .17792E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          17.973        17.101        .94475E-04   -1.4860    
   3  Prefactor     39.336        48.195        .63906E-04   -1.4453    
   4  norm          .10000E-03    4.3456        .36060E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          .10000E-03    1.6189        .13586E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10000E-03    11.605        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .13878        47.402        .36376E-02   -1.5633    
   8  Prefactor     .10000E-03    4.7279        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     19.779        30.215        .90058E-04   -1.4818    
  10  norm          .10000E-03    10.954        .13618E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     20.756        19.892        .87916E-04   -1.4796    
  12  norm          .10000E-03    11.560        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    .89054        .82745E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    7.1315        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     18.393        11.543        .93384E-04   -1.4850    
  16  Prefactor     .10000E-03    11.076        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    9.6910        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    8.5723        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          3.8296        3.2135        .67185E-03   -1.5317    
  20  norm          .15206        3.5175        .15573E-02   -1.5630    
  21  norm          11.888        15.703        .11617E-03   -1.5018    
  22  norm          .10000E-03    3.6273        .23370E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    7.8398        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .74114        .19032        .41987E-03   -1.0229    
  25  Prefactor     .96525        .68508E-01    .13865E-03   -.93897    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.50762e-08
Minuit parameter uncertainties:
  1  1.69782e-05
  2  17.1054
  3  48.2423
  4  1.89596e-05
  5  1.98028e-06
  6  4.48944e-05
  7  5.132
  8  1.39373e-05
  9  30.2383
  10  0.000380368
  11  19.8979
  12  3.44728e-05
  13  2.43076e-07
  14  1.67054e-05
  15  11.5443
  16  3.25906e-05
  17  4.53671e-05
  18  1.1984e-05
  19  3.21366
  20  1.46228
  21  15.7083
  22  3.80461e-06
  23  3.60667e-05
  24  0.190487
  25  0.068514
Done.

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

Extracting fit parameters...

4FGL J0739.2+0137
   Spectrum: LogParabola
204         norm:  1.000e-04  3.804e-04  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.653e-01  6.851e-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:  7.411e-01  1.905e-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.08e-08 ph cm-2 s-1
Energy Flux Upper Limit: 2.94e-05 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/587833/likelihoodResults_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.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) = 8100.49275622
delta logL = -0.000445985075203

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 8100.49231011
delta logL = 1.27841303765e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10448E-03   1.0000         .10000E-03   10000.    
     2 'alpha     '    2.2689       1.0000          .0000       5.0000    
     3 'Normalizat'    .74110       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .96526       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.

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

 FCN=   8100.492     FROM MIGRAD    STATUS=FAILED       103 CALLS      282 TOTAL
                     EDM=   .75E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10025E-03    684.14        .13821E-02** at limit **
   2  alpha         2.1674        3.1720        .50000        .45031E-06
   3  Normalizat    .74114        .43521E-01    .41987E-03   -.12723E-03
   4  Prefactor     .96525        .16353E-01    .13865E-03   -.20222E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   8100.492     FROM SIMPLEX   STATUS=UNCHANGED    150 CALLS      432 TOTAL
                     EDM=   .13E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10025E-03    684.14        .59737E-03** at limit **
   2  alpha         2.1674        3.1720        .10416E-04    .45031E-06
   3  Normalizat    .74114        .43521E-01    .29400E-06   -.12723E-03
   4  Prefactor     .96525        .16353E-01    .95123E-07   -.20222E-03
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   8100.492     FROM MIGRAD    STATUS=CONVERGED     34 CALLS      466 TOTAL
                     EDM=   .54E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10005E-03    15.555        .55283E-04** at limit **
   2  alpha         2.1743        2.6344        .50000        .15752E-05
   3  Normalizat    .74114        .17774        .16795E-04   -.11765E-03
   4  Prefactor     .96525        .66892E-01    .27729E-04   -.17597E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.000100052
  alpha      = 2.17429
  Normalizat = 0.741138
  Prefactor  = 0.965254
 **********
 **   18 **HESSE 
 **********

 FCN=   8100.492     FROM HESSE     STATUS=OK            29 CALLS      495 TOTAL
                     EDM=   .66E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10005E-03    13.432        .11057E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  alpha         2.1743        2.6171        .50000       -.13065    
   3  Normalizat    .74114        .17778        .33590E-05   -1.0229    
   4  Prefactor     .96525        .66902E-01    .55458E-05   -.93897    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.6445e-09
Minuit parameter uncertainties:
  1  0.00167643
  2  93.2114
  3  0.177916
  4  0.0669076
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/587833': 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) = 8100.49230955
delta logL = 6.83482539898e-07

Extracting fit parameters...

4FGL J0739.2+0137
   Spectrum: LogParabola
204         norm:  1.001e-04  1.676e-03  1.000e-04  1.000e+04 ( 1.000e-11)
205        alpha:  2.174e+00  9.321e+01  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.653e-01  6.691e-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:  7.411e-01  1.779e-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/587833/cmap_HighResolution_374371201_374630401_4FGL_J0739.2+0137_daily_bin521.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.94e-05', job_status='DONE', photon_flux_upper_limit='9.08e-08', time_completed='2021-08-27 20:27:13.615709', job_id='587833', GAL2='0.97', fit_tolerance='1e-08', EG2='0.74', EG='0.74', time_epoch_completed='1630121233.62', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.97', dlogl='6.83e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.31' WHERE bin_id='521' AND source_name='4FGL J0739.2+0137' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Fri Aug 27 20:27:13 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0238>
Subject: Job 587833: <4FGL_J0739.2+0137_daily_bin521> in cluster <slac> Done

Job <4FGL_J0739.2+0137_daily_bin521> was submitted from host <rhel6-64q> by user <kocevski> in cluster <slac> at Fri Aug 27 20:10:48 2021
Job was executed on host(s) <bullet0238>, in queue <medium>, as user <kocevski> in cluster <slac> at Fri Aug 27 20:10:57 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:10:57 2021
Terminated at Fri Aug 27 20:27:15 2021
Results reported at Fri Aug 27 20:27:15 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0739.2+0137_daily_bin521 114.82 1.6216 374371201 374630401 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 :                                   954.15 sec.
    Max Memory :                                 1255 MB
    Average Memory :                             324.93 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              7
    Max Threads :                                21
    Run time :                                   977 sec.
    Turnaround time :                            987 sec.

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

