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


Performing analysis on: 4FGL_J1257.2+3646_daily_bin1163
RA = 194.31, Dec = 36.7706
tmin = 540777601, tmax = 541036801
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='38664', job_status='RUN', time_executed='2021-09-06 11:46:07.448883', time_epoch_executed='1630953967.45' WHERE source_name='4FGL J1257.2+3646' and cadence='daily' and bin_id='1163'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/38664

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

Retrieving the FT1 file...

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

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

Retrieving 48 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/38664/ft1_4FGL_J1257.2+3646_daily_bin1163.fits


Retrieving the FT1 file...

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

Retrieving 48 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/38664/ft1_4FGL_J1257.2+3646_daily_bin1163.fits outfile=/scratch/kocevski/38664/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin1163.fits ra=194.31 dec=36.7706 rad=12.0 tmin=540777601.0 tmax=541036801.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.63
user 3.40
sys 0.18

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

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.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/38664/ft1_filteredMKT_4FGL_J1257.2+3646_daily_bin1163.fits evtable="EVENTS" outfile="/scratch/kocevski/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.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.62
user 0.32
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits" evtable="EVENTS" scfile=/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits sctable="SC_DATA" outfile=/scratch/kocevski/38664/ltcube_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.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/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits
.....................!
real 12.32
user 11.52
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits evtable="EVENTS" scfile=/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits sctable="SC_DATA" expcube=/scratch/kocevski/38664/ltcube_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits outfile=/scratch/kocevski/38664/expmap_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.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/38664/ltcube_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits
.....................!
real 192.90
user 186.04
sys 4.79

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/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits scfile=/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits outfile=/scratch/kocevski/38664/cmap_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.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 2.42
user 0.37
sys 0.19

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits scfile=/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits outfile=/scratch/kocevski/38664/cmap_HighResolution_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.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 1.95
user 0.38
sys 0.19

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

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits', '/scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits', expMap='/scratch/kocevski/38664/expmap_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits', expCube='/scratch/kocevski/38664/ltcube_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/38664/Model_4FGL_J1257.2+3646_daily_bin1163.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/38664/ft1_filtered_4FGL_J1257.2+3646_daily_bin1163.fits
Spacecraft file(s): /scratch/kocevski/38664/ft2_4FGL_J1257.2+3646_daily_bin1163.fits
Exposure map: /scratch/kocevski/38664/expmap_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits
Exposure cube: /scratch/kocevski/38664/ltcube_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/38664/Model_4FGL_J1257.2+3646_daily_bin1163.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) = 5800.42305018

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    4.4429       1.0000         .10000E-03   10000.    
     2 'norm      '    .10024E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    9.9950       1.0000         .10000E-03   10000.    
     5 'Prefactor '    2.5094       1.0000         .10000E-03   10000.    
     6 'Prefactor '    6.0231       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    2.5165       1.0000         .10000E-03   10000.    
    11 'norm      '    .29384E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    30.920       1.0000         .10000E-03   10000.    
    15 'norm      '    .10008E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10086E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    15.896       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    1.4263       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .38083       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.

 FCN=   5800.369     FROM MIGRAD    STATUS=CONVERGED    603 CALLS     2936 TOTAL
                     EDM=   .99E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .4%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     4.4340        65.429       -.13706E-04   -.45138E-04
   2  norm          .10003E-03    1.9043        .18280E-05** at limit **
   3  Prefactor     .10000E-03    3.0822       -.29861E-06** at limit **
   4  Prefactor     9.9945        3.5680       -.20664E-06   -.24554E-02
   5  Prefactor     2.5095        2.0609        .10907E-07   -.49102E-03
   6  Prefactor     6.0229        11.189       -.42208E-06   -.20296E-03
   7  Prefactor     .10000E-03    11.066       -.66417E-05** at limit **
   8  Prefactor     .10000E-03    6.2161       -.71459E-05** at limit **
   9  Prefactor     .10000E-03    116.14       -.11520E-04** at limit **
  10  Prefactor     2.5170        5.6774       -.74040E-06   -.55509E-03
  11  norm          .10001E-03    2.3180        .32261E-06** at limit **
  12  Prefactor     .10000E-03    18.583        .16992E-04** at limit **
  13  Prefactor     .10000E-03    9.9509        .36650E-05** at limit **
  14  Prefactor     30.917        19.688        .14682E-06   -.16539E-03
  15  norm          .10000E-03    2.1298        .27715E-07** at limit **
  16  norm          .10000E-03    4.8442       -.81978E-06** at limit **
  17  norm          .10000E-03    2.0914       -.22037E-07** at limit **
  18  norm          .10000E-03    1.9242        .31098E-06** at limit **
  19  Prefactor     .10000E-03    2.1570       -.10440E-06** at limit **
  20  Prefactor     .10000E-03    7.3774        .15339E-05** at limit **
  21  Prefactor     .10000E-03    44.787        .10367E-04** at limit **
  22  Prefactor     15.897        17.776       -.41776E-06   -.26051E-04
  23  Prefactor     .10000E-03    21.717       -.18913E-04** at limit **
  24  Normalizat    1.4262        .18548        .33465E-06   -.32546E-03
  25  Prefactor     .38101        .21084       -.11242E-05   -.17453E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 4.43397
  norm       = 0.000100031
  Prefactor  = 0.0001
  Prefactor  = 9.99451
  Prefactor  = 2.50947
  Prefactor  = 6.02285
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 2.51697
  norm       = 0.000100014
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 30.9167
  norm       = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 15.8968
  Prefactor  = 0.0001
  Normalizat = 1.42616
  Prefactor  = 0.381009
 **********
 **   18 **HESSE 
 **********

 FCN=   5800.369     FROM HESSE     STATUS=OK           419 CALLS     3355 TOTAL
                     EDM=   .66E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     4.4340        65.792        .19104E-03   -1.5287    
   2  norm          .10003E-03    5.8975        .18850E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    3.1021        .13055E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     9.9945        3.3609        .77249E-04   -1.5076    
   5  Prefactor     2.5095        2.0547        .94615E-04   -1.5391    
   6  Prefactor     6.0229        11.151        .16361E-03   -1.5217    
   7  Prefactor     .10000E-03    11.069        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    6.2059        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    116.43        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     2.5170        5.6466        .24665E-03   -1.5391    
  11  norm          .10001E-03    24.988        .22221E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    18.560        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10000E-03    9.9628        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     30.917        19.559        .36028E-03   -1.4595    
  15  norm          .10000E-03    2.1356        .10845E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          .10000E-03    4.8501        .16371E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .10000E-03    2.1448        .21475E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    1.9322        .10316E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    4.2264        .21378E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    7.4112        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    44.902        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     15.897        17.825        .10046E-03   -1.4910    
  23  Prefactor     .10000E-03    21.680        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    1.4262        .20492        .19547E-03   -.79875    
  25  Prefactor     .38101        .23019        .41147E-03   -1.1779    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.58402e-09
Minuit parameter uncertainties:
  1  34.2044
  2  0.000848915
  3  7.13302e-06
  4  3.36093
  5  2.05475
  6  11.1551
  7  1.97095e-06
  8  3.71766e-06
  9  3.55517e-05
  10  5.64774
  11  0.00118147
  12  1.35567e-06
  13  8.72049e-07
  14  19.5632
  15  1.02491e-06
  16  1.88455e-08
  17  1.01549e-06
  18  3.28741e-07
  19  9.8463e-06
  20  3.66159e-07
  21  8.12831e-06
  22  17.8306
  23  4.02969e-06
  24  0.205034
  25  0.230748
Done.

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

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  2.517e+00  5.648e+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

GAL_V02
   Spectrum: PowerLaw
599    Prefactor:  3.810e-01  2.307e-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.426e+00  2.050e-01  1.000e-02  1.000e+01 ( 1.000e+00)


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

Saving results to:
/scratch/kocevski/38664/likelihoodResults_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.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) = 5800.07255929
delta logL = 0.296212708114

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 5800.06221245
delta logL = 0.306559545159

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    1.2807       1.0000         .10000E-03   10000.    
     2 'Index     '    2.8898       1.0000          .0000       10.000    
     3 'Normalizat'    1.4022       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .39582       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=   5800.062     FROM MIGRAD    STATUS=CONVERGED     55 CALLS      262 TOTAL
                     EDM=   .78E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     1.2802        35.741        .98051E-02   -.20231E-03
   2  Index         2.8900        3.2585        .12533        .47838E-05
   3  Normalizat    1.4022        .42118E-01    .31188E-01   -.19143E-05
   4  Prefactor     .39577        .46717E-01    .91124E-01    .35090E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 1.28021
  Index      = 2.89
  Normalizat = 1.40224
  Prefactor  = 0.395766
 **********
 **   18 **HESSE 
 **********

 FCN=   5800.062     FROM HESSE     STATUS=OK            33 CALLS      295 TOTAL
                     EDM=   .17E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     1.2802        4.9650        .10037E-03   -1.5482    
   2  Index         2.8900        1.7991        .67226E-02   -.43565    
   3  Normalizat    1.4022        .20624        .19670E-03   -.80564    
   4  Prefactor     .39577        .23310        .40387E-03   -1.1702    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.72352e-10
Minuit parameter uncertainties:
  1  4.9666
  2  1.85008
  3  0.206363
  4  0.233663
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/38664': 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) = 5800.06221236
delta logL = 0.306559636954

Extracting fit parameters...

4FGL J1257.2+3646
   Spectrum: PowerLaw
300    Prefactor:  1.280e+00  4.967e+00  1.000e-04  1.000e+04 ( 1.000e-13)
301        Index:  2.890e+00  1.850e+00  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:  3.958e-01  2.337e-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.402e+00  2.064e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 0.27
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/38664/cmap_HighResolution_540777601_541036801_4FGL_J1257.2+3646_daily_bin1163.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='4.80e-03', job_status='DONE', photon_flux_upper_limit='6.39e-08', time_completed='2021-09-06 11:58:10.178746', job_id='38664', GAL2='0.40', fit_tolerance='1e-08', EG2='1.40', EG='1.43', time_epoch_completed='1630954690.18', return_code2='0', ts='0.27', comment='SUCCESS', return_code='0', GAL='0.38', dlogl='3.07e-01', ts2='0.90', photon_index_error='0.00', photon_index='2.03' WHERE bin_id='1163' AND source_name='4FGL J1257.2+3646' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Mon Sep  6 11:58:10 PDT 2021


------------------------------------------------------------
Sender: LSF System <scs@bullet0139>
Subject: Job 38664: <4FGL_J1257.2+3646_daily_bin1163> in cluster <slac> Done

Job <4FGL_J1257.2+3646_daily_bin1163> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Mon Sep  6 11:45:51 2021
Job was executed on host(s) <bullet0139>, in queue <medium>, as user <kocevski> in cluster <slac> at Mon Sep  6 11:45:53 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:45:53 2021
Terminated at Mon Sep  6 11:58:11 2021
Results reported at Mon Sep  6 11:58:11 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1257.2+3646_daily_bin1163 194.31 36.7706 540777601 541036801 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 :                                   693.27 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             363.33 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   737 sec.
    Turnaround time :                            740 sec.

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

