/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 121 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 = 7388
number of fields = 27
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1257.2+3646_daily_bin169
RA = 194.31, Dec = 36.7706
tmin = 283132801, tmax = 283392001
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='31933', job_status='RUN', time_executed='2021-09-06 11:28:01.785524', time_epoch_executed='1630952881.79' WHERE source_name='4FGL J1257.2+3646' and cadence='daily' and bin_id='169'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/31933

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/31933/ft1_4FGL_J1257.2+3646_daily_bin169.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/31933/ft1_4FGL_J1257.2+3646_daily_bin169.fits outfile=/scratch/kocevski/31933/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin169.fits ra=194.31 dec=36.7706 rad=12.0 tmin=283132801.0 tmax=283392001.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.82
user 3.56
sys 0.19

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.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/31933/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin169.fits evtable="EVENTS" outfile="/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.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.50
user 0.34
sys 0.13

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits" evtable="EVENTS" scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits sctable="SC_DATA" outfile=/scratch/kocevski/31933/ltcube_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.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/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits
.....................!
real 11.44
user 11.08
sys 0.32

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits evtable="EVENTS" scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits sctable="SC_DATA" expcube=/scratch/kocevski/31933/ltcube_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits outfile=/scratch/kocevski/31933/expmap_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.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/31933/ltcube_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits
.....................!
real 189.50
user 184.97
sys 4.17

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

Setting source of interest to:
4FGL J1257.2+3646 @ 194.31 36.7706

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits outfile=/scratch/kocevski/31933/cmap_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.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=194.31 yref=36.7706 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.37
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits outfile=/scratch/kocevski/31933/cmap_HighResolution_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.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=194.31 yref=36.7706 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.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits evtable="EVENTS" scfile=/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/31933/Model_4FGL_J1257.2+3646_daily_bin169.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/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits.....................!
real 49.28
user 46.88
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits', '/scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits', expMap='/scratch/kocevski/31933/expmap_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits', expCube='/scratch/kocevski/31933/ltcube_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/31933/Model_4FGL_J1257.2+3646_daily_bin169.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1257.2+3646'

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.472e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/31933/ft1_filtered_4FGL_J1257.2+3646_daily_bin169.fits
Spacecraft file(s): /scratch/kocevski/31933/ft2_4FGL_J1257.2+3646_daily_bin169.fits
Exposure map: /scratch/kocevski/31933/expmap_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits
Exposure cube: /scratch/kocevski/31933/ltcube_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/31933/Model_4FGL_J1257.2+3646_daily_bin169.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) = 5580.47492774

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .11374E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    8.4217       1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10009E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    4.1379       1.0000         .10000E-03   10000.    
     5 'Prefactor '    1.6901       1.0000         .10000E-03   10000.    
     6 'Prefactor '    14.850       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10047E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    10.670       1.0000         .10000E-03   10000.    
     9 'Prefactor '    12.899       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10021E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .10165E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10244E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10550E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10014E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    .10002E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10203E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    3.3900       1.0000         .10000E-03   10000.    
    18 'norm      '    .11304E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .55895       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .14156E-02   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10015E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    1.6574       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10527E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    1.0328       1.0000         .10000E-01   10.000    
    25 'Prefactor '    1.0825       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6020E+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=   5580.432     FROM MIGRAD    STATUS=FAILED      1030 CALLS     2921 TOTAL
                     EDM=   .30E-07    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    25.190        .18142E-02** at limit **
   2  norm          8.4208        4.1042        .96049E-04    .26277E-04
   3  Prefactor     .10000E-03    4.7569        .15829E-02** at limit **
   4  Prefactor     4.1367        2.8085        .94348E-04    .20123E-04
   5  Prefactor     1.6924        2.8175        .15080E-03    .22240E-04
   6  Prefactor     14.843        11.171        .10394E-03    .17829E-04
   7  Prefactor     .10000E-03    29.293        .18142E-02** at limit **
   8  Prefactor     10.671        10.712        .12266E-03    .26879E-05
   9  Prefactor     12.933        91.386        .11153E-03   -.50968E-06
  10  Prefactor     .10000E-03    2.9000        .12338E-02** at limit **
  11  norm          .10000E-03    1.4306        .87156E-03** at limit **
  12  Prefactor     .10000E-03    54.732        .18142E-02** at limit **
  13  Prefactor     .10000E-03    12.434        .18142E-02** at limit **
  14  Prefactor     .10000E-03    7.3846        .18142E-02** at limit **
  15  norm          .10000E-03    3.0346        .12626E-02** at limit **
  16  norm          .10000E-03    6.0654        .17961E-02** at limit **
  17  norm          3.3973        3.6254        .13750E-03   -.25631E-04
  18  norm          .10000E-03    4.8164        .15852E-02** at limit **
  19  Prefactor     .55884        6.2290        .22593E-02    .34650E-02
  20  Prefactor     .10000E-03    23.095        .71094E-01** at limit **
  21  Prefactor     .10000E-03    21.309        .18142E-02** at limit **
  22  Prefactor     1.6572        24.977        .16389E-02    .17800E-04
  23  Prefactor     .10000E-03    50.305        .18142E-02** at limit **
  24  Normalizat    1.0325        .21927        .23276E-03    .12025E-03
  25  Prefactor     1.0828        .26910        .28212E-03    .57665E-04
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5580.432     FROM SIMPLEX   STATUS=UNCHANGED   1291 CALLS     4212 TOTAL
                     EDM=   .17E-04    STRATEGY= 1      ERR MATRIX APPROXIMATE

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    25.190        .56862E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          8.4208        4.1042        .84956E-06   -1.5128    
   3  Prefactor     .10000E-03    4.7569        .29353E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     4.1367        2.8085        .85973E-06   -1.5301    
   5  Prefactor     1.6924        2.8175        .86815E-06   -1.5448    
   6  Prefactor     14.843        11.171        .83942E-06   -1.4937    
   7  Prefactor     .10000E-03    29.293        .38067E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     10.671        10.712        .84596E-06   -1.5055    
   9  Prefactor     12.933        91.386        .84239E-06   -1.4989    
  10  Prefactor     .10000E-03    2.9000        .16859E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    1.4306        .13217E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    54.732        .66321E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    12.434        .20643E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    7.3846        .19522E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    3.0346        .88763E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    6.0654        .30050E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          3.3973        3.6254        .86192E-06   -1.5339    
  18  norm          .10000E-03    4.8164        .17798E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .55884        6.2290        .87504E-06   -1.5558    
  20  Prefactor     .10000E-03    23.095        .97181E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    21.309        .44843E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     1.6572        24.977        .86807E-06   -1.5451    
  23  Prefactor     .10000E-03    50.305        .33243E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    1.0325        .21927        .51662E-06   -.91948    
  25  Prefactor     1.0828        .26910        .50581E-06   -.90018    
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5580.432     FROM MIGRAD    STATUS=CONVERGED    418 CALLS     4630 TOTAL
                     EDM=   .46E-12    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    25.195        .36285E-03** at limit **
   2  norm          8.4208        4.1041        .38419E-05    .11836E-06
   3  Prefactor     .10000E-03    4.7583        .31659E-03** at limit **
   4  Prefactor     4.1367        2.8085        .37739E-05    .12050E-06
   5  Prefactor     1.6924        2.8170        .60319E-05    .37695E-06
   6  Prefactor     14.843        11.170        .41574E-05    .54691E-06
   7  Prefactor     .10000E-03    29.296        .36285E-03** at limit **
   8  Prefactor     10.671        10.712        .49064E-05     .0000    
   9  Prefactor     12.933        91.506        .44611E-05    .10194E-06
  10  Prefactor     .10000E-03    2.9007        .24677E-03** at limit **
  11  norm          .10000E-03    1.4306        .17431E-03** at limit **
  12  Prefactor     .10000E-03    54.741        .36285E-03** at limit **
  13  Prefactor     .10000E-03    12.436        .36285E-03** at limit **
  14  Prefactor     .10000E-03    7.3857        .36285E-03** at limit **
  15  norm          .10000E-03    3.0353        .25251E-03** at limit **
  16  norm          .10000E-03    6.0656        .35922E-03** at limit **
  17  norm          3.3973        3.6217        .55000E-05    .20670E-05
  18  norm          .10000E-03    4.8167        .31705E-03** at limit **
  19  Prefactor     .55885        5.9723        .45185E-03    .13083E-04
  20  Prefactor     .10000E-03    18.858        .79456E-01** at limit **
  21  Prefactor     .10000E-03    21.310        .36285E-03** at limit **
  22  Prefactor     1.6572        24.953        .65555E-04    .34684E-06
  23  Prefactor     .10000E-03    50.307        .36285E-03** at limit **
  24  Normalizat    1.0325        .21947        .93104E-05    .19537E-05
  25  Prefactor     1.0828        .26940        .11285E-04    .12089E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  norm       = 8.42078
  Prefactor  = 0.0001
  Prefactor  = 4.13674
  Prefactor  = 1.6924
  Prefactor  = 14.8429
  Prefactor  = 0.0001
  Prefactor  = 10.6712
  Prefactor  = 12.9334
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  norm       = 3.39729
  norm       = 0.0001
  Prefactor  = 0.558848
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 1.65717
  Prefactor  = 0.0001
  Normalizat = 1.03254
  Prefactor  = 1.0828
 **********
 **   18 **HESSE 
 **********

 FCN=   5580.432     FROM HESSE     STATUS=OK           413 CALLS     5043 TOTAL
                     EDM=   .18E-12    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    25.195        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          8.4208        4.1041        .38419E-05   -1.5128    
   3  Prefactor     .10000E-03    4.7584        .63318E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     4.1367        2.8085        .37739E-05   -1.5301    
   5  Prefactor     1.6924        2.8168        .12064E-05   -1.5448    
   6  Prefactor     14.843        11.171        .83149E-06   -1.4937    
   7  Prefactor     .10000E-03    29.296        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     10.671        10.712        .49064E-05   -1.5055    
   9  Prefactor     12.933        91.486        .44611E-05   -1.4989    
  10  Prefactor     .10000E-03    2.9007        .49354E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    1.4306        .34863E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    54.741        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    12.436        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    7.3858        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          .10000E-03    3.0353        .50503E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    6.0656        .71844E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          3.3973        3.6200        .11000E-05   -1.5339    
  18  norm          .10000E-03    4.8167        .63410E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .55885        5.9438        .18074E-04   -1.5558    
  20  Prefactor     .10000E-03    19.869        .76609E-01   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    21.310        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     1.6572        24.914        .26222E-05   -1.5451    
  23  Prefactor     .10000E-03    50.307        .72569E-04   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    1.0325        .21918        .18621E-05   -.91948    
  25  Prefactor     1.0828        .26913        .22570E-05   -.90018    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.76242e-13
Minuit parameter uncertainties:
  1  4.26843e-07
  2  4.10421
  3  1.05e-07
  4  2.80858
  5  2.81707
  6  11.1729
  7  8.63343e-07
  8  10.7138
  9  68.9462
  10  5.34203e-08
  11  8.6116e-09
  12  1.36014e-06
  13  1.1408e-07
  14  1.41447e-07
  15  2.16107e-08
  16  4.72083e-08
  17  3.62019
  18  1.89191e-07
  19  3.64522
  20  4.04001e-05
  21  5.96067e-09
  22  12.8569
  23  8.90672e-07
  24  0.21937
  25  0.26947
Done.

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

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.000e-04  5.342e-08  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.027e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
599    Prefactor:  1.083e+00  2.695e-01  0.000e+00  1.000e+01 ( 1.000e+00)
600        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
601        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
598   Normalization:  1.033e+00  2.194e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 194.310 36.771
Photon Flux Upper Limit: 4.11e-08 ph cm-2 s-1
Energy Flux Upper Limit: 3.09e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/31933/likelihoodResults_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.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) = 5580.43374
delta logL = -0.00163590785178

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5580.43210425
delta logL = -1.52538632392e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.0239       1.0000          .0000       10.000    
     3 'Normalizat'    1.0325       1.0000         .10000E-01   10.000    
     4 'Prefactor '    1.0829       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6020E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5580.432     FROM MIGRAD    STATUS=CONVERGED     51 CALLS      199 TOTAL
                     EDM=   .97E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    1.9008        .90712E-02** at limit **
   2  Index         2.0204        8.9318        .50000        .93510E-05
   3  Normalizat    1.0325        .35196E-02    .41928E-01    .20901E-04
   4  Prefactor     1.0828        .43776E-02    .63782E-01    .11512E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Index      = 2.02038
  Normalizat = 1.03254
  Prefactor  = 1.0828
 **********
 **   18 **HESSE 
 **********

 FCN=   5580.432     FROM HESSE     STATUS=NOT POSDEF    33 CALLS      232 TOTAL
                     EDM=   .17E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    34.525        .12347E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.0204        5.9880        .50000       -.63842    
   3  Normalizat    1.0325        .15072E-01    .23276E-03   -.91948    
   4  Prefactor     1.0828        .18732E-01    .28212E-03   -.90018    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 1.73382e-07
Minuit parameter uncertainties:
  1  1.37081e-05
  2  179.807
  3  0.0150722
  4  0.0187325
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/31933': 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): 102
logL (Free Index) = 5580.43210408
delta logL = 1.6709236661e-08

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.000e-04  1.371e-05  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.020e+00  1.798e+02  0.000e+00  1.000e+01 (-1.000e+00)
302        Scale:  1.897e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
599    Prefactor:  1.083e+00  1.873e-02  0.000e+00  1.000e+01 ( 1.000e+00)
600        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
601        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
598   Normalization:  1.033e+00  1.507e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 194.310 36.771

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/31933/cmap_HighResolution_283132801_283392001_4FGL_J1257.2+3646_daily_bin169.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.09e-03', job_status='DONE', photon_flux_upper_limit='4.11e-08', time_completed='2021-09-06 11:41:07.526829', job_id='31933', GAL2='1.08', fit_tolerance='1e-08', EG2='1.03', EG='1.03', time_epoch_completed='1630953667.53', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='1.08', dlogl='1.67e-08', ts2='-0.00', photon_index_error='0.00', photon_index='2.03' WHERE bin_id='169' AND source_name='4FGL J1257.2+3646' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 11:41:07 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0260>
Subject: Job 31933: <4FGL_J1257.2+3646_daily_bin169> in cluster <slac> Done

Job <4FGL_J1257.2+3646_daily_bin169> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Mon Sep  6 11:25:47 2021
Job was executed on host(s) <bullet0260>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 11:25:49 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Mon Sep  6 11:25:49 2021
Terminated at Mon Sep  6 11:41:08 2021
Results reported at Mon Sep  6 11:41:08 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1257.2+3646_daily_bin169 194.31 36.7706 283132801 283392001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1257.2+3646 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   780.22 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             305.29 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              7
    Max Threads :                                21
    Run time :                                   918 sec.
    Turnaround time :                            921 sec.

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

