/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 0 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 = 7560
number of fields = 22
No RA_SUN column yet. Adding RA_SUN/DEC_SUN columns.
Done.


Performing analysis on: 4FGL_J1330.2+7002_daily_bin56
RA = 202.573, Dec = 70.0406
tmin = 253843201, tmax = 254102401
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='631537', job_status='RUN', time_executed='2021-09-07 21:02:03.539873', time_epoch_executed='1631073723.54' WHERE source_name='4FGL J1330.2+7002' and cadence='daily' and bin_id='56'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/631537

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/631537/ft1_4FGL_J1330.2+7002_daily_bin56.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/631537/ft1_4FGL_J1330.2+7002_daily_bin56.fits outfile=/scratch/kocevski/631537/ft1_filteredMKT_4FGL_J1330.2+7002_daily_bin56.fits ra=202.573 dec=70.0406 rad=12.0 tmin=253843201.0 tmax=254102401.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 1.49
user 1.33
sys 0.14

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.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/631537/ft1_filteredMKT_4FGL_J1330.2+7002_daily_bin56.fits evtable="EVENTS" outfile="/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.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.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits" evtable="EVENTS" scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits sctable="SC_DATA" outfile=/scratch/kocevski/631537/ltcube_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.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/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits
.....................!
real 15.13
user 14.78
sys 0.29

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits evtable="EVENTS" scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits sctable="SC_DATA" expcube=/scratch/kocevski/631537/ltcube_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits outfile=/scratch/kocevski/631537/expmap_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.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/631537/ltcube_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits
.....................!
real 190.15
user 185.51
sys 3.99

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

Setting source of interest to:
4FGL J1330.2+7002 @ 202.573 70.0406

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits outfile=/scratch/kocevski/631537/cmap_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.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=202.573 yref=70.0406 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.55
user 0.40
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits outfile=/scratch/kocevski/631537/cmap_HighResolution_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.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=202.573 yref=70.0406 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.56
user 0.40
sys 0.14

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits evtable="EVENTS" scfile=/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/631537/Model_4FGL_J1330.2+7002_daily_bin56.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/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits.....................!
real 55.53
user 53.78
sys 1.09

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits', '/scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits', expMap='/scratch/kocevski/631537/expmap_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits', expCube='/scratch/kocevski/631537/ltcube_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/631537/Model_4FGL_J1330.2+7002_daily_bin56.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1330.2+7002'

4FGL J1330.2+7002
   Spectrum: PowerLaw
379    Prefactor:  5.366e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
380        Index:  1.967e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
381        Scale:  2.478e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/631537/ft1_filtered_4FGL_J1330.2+7002_daily_bin56.fits
Spacecraft file(s): /scratch/kocevski/631537/ft2_4FGL_J1330.2+7002_daily_bin56.fits
Exposure map: /scratch/kocevski/631537/expmap_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits
Exposure cube: /scratch/kocevski/631537/ltcube_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/631537/Model_4FGL_J1330.2+7002_daily_bin56.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) = 5017.50486939

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
     2 'Prefactor '    .35763E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    29.317       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    16.462       1.0000         .10000E-03   10000.    
     6 'Prefactor '    80.043       1.0000         .10000E-03   10000.    
     7 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    .46296       1.0000         .10000E-03   10000.    
     9 'Prefactor '    53.367       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    25.147       1.0000         .10000E-03   10000.    
    13 'Prefactor '    2.4597       1.0000         .10000E-03   10000.    
    14 'Prefactor '    9.6093       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10002E-03   1.0000         .10000E-03   10000.    
    16 'Prefactor '    7.0370       1.0000         .10000E-03   10000.    
    17 'Prefactor '    13.344       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10146E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .18800E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    26.792       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10247E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    25 'Prefactor '    24.079       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .23272E-03   1.0000         .10000E-03   10000.    
    27 'Normalizat'    .92628       1.0000         .10000E-01   10.000    
    28 'Prefactor '    .91300       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7350E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   5017.502     FROM MIGRAD    STATUS=CONVERGED    692 CALLS     4271 TOTAL
                     EDM=   .51E-10  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10000E-03    15.744        .95783E-07** at limit **
   2  Prefactor     .10000E-03    2.3713       -.10001E-06** at limit **
   3  Prefactor     29.321        62.015       -.36553E-06   -.85036E-06
   4  Prefactor     .10000E-03    31.609        .13208E-07** at limit **
   5  Prefactor     16.466        35.589        .15004E-05   -.30067E-05
   6  Prefactor     80.032        109.79       -.11515E-06   -.39214E-05
   7  norm          .10000E-03    6.9495        .18986E-07** at limit **
   8  norm          .45998        3.1742        .48172E-06   -.20228E-03
   9  Prefactor     53.370        51.497        .20495E-07   -.56947E-07
  10  Prefactor     .10000E-03    37.431        .62825E-07** at limit **
  11  Prefactor     .10000E-03    14.922       -.82083E-07** at limit **
  12  Prefactor     25.147        47.070       -.36746E-06   -.56904E-05
  13  Prefactor     2.4584        4.1805        .23372E-06   -.76277E-05
  14  Prefactor     9.6093        20.224       -.37772E-06   -.14825E-04
  15  Prefactor     .10000E-03    8.4262       -.84848E-07** at limit **
  16  Prefactor     7.0373        10.748        .36362E-05   -.33050E-04
  17  Prefactor     13.347        20.255       -.58778E-06   -.19974E-04
  18  Prefactor     .10000E-03    75.273       -.75460E-06** at limit **
  19  Prefactor     .10001E-03    432.65       -.25325E-05** at limit **
  20  Prefactor     .10000E-03    20.800        .57054E-07** at limit **
  21  Prefactor     26.790        19.915        .92992E-07   -.57747E-05
  22  Prefactor     .10000E-03    155.58        .30944E-05** at limit **
  23  Prefactor     .10000E-03    13.482        .30401E-07** at limit **
  24  Prefactor     .10000E-03    23.353       -.93163E-07** at limit **
  25  Prefactor     24.045        20.761        .14501E-05   -.17118E-04
  26  Prefactor     .10000E-03    174.77        .12249E-06** at limit **
  27  Normalizat    .92625        .18572       -.43194E-06   -.33353E-04
  28  Prefactor     .91291        .17661       -.21407E-06   -.60399E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 29.3213
  Prefactor  = 0.0001
  Prefactor  = 16.4665
  Prefactor  = 80.0315
  norm       = 0.0001
  norm       = 0.459983
  Prefactor  = 53.3704
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 25.1471
  Prefactor  = 2.4584
  Prefactor  = 9.60933
  Prefactor  = 0.0001
  Prefactor  = 7.03733
  Prefactor  = 13.3474
  Prefactor  = 0.0001
  Prefactor  = 0.000100015
  Prefactor  = 0.0001
  Prefactor  = 26.7905
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 24.0452
  Prefactor  = 0.0001
  Normalizat = 0.926248
  Prefactor  = 0.912915
 **********
 **   18 **HESSE 
 **********

 FCN=   5017.502     FROM HESSE     STATUS=OK           517 CALLS     4788 TOTAL
                     EDM=   .22E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10000E-03    15.793        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     .10000E-03    13.202        .21169E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     29.321        61.905        .73995E-04   -1.4624    
   4  Prefactor     .10000E-03    31.630        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     16.466        35.737        .49357E-03   -1.4896    
   6  Prefactor     80.032        109.76        .44890E-04   -1.3916    
   7  norm          .10000E-03    7.1503        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .45998        6.3849        .23664E-02   -1.5572    
   9  Prefactor     53.370        51.512        .54904E-04   -1.4246    
  10  Prefactor     .10000E-03    37.446        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10000E-03    14.927        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     25.147        46.967        .79882E-04   -1.4705    
  13  Prefactor     2.4584        4.1519        .17888E-03   -1.5394    
  14  Prefactor     9.6093        20.201        .12928E-03   -1.5088    
  15  Prefactor     .10000E-03    8.4772        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  Prefactor     7.0373        10.805        .75613E-03   -1.5177    
  17  Prefactor     13.347        20.275        .10965E-03   -1.4977    
  18  Prefactor     .10000E-03    76.081        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10001E-03    433.60        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    20.801        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     26.790        19.914        .77395E-04   -1.4672    
  22  Prefactor     .10000E-03    159.17        .36285E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    13.487        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     .10000E-03    23.358        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     24.045        20.714        .81631E-04   -1.4727    
  26  Prefactor     .10000E-03    176.59        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Normalizat    .92625        .22069        .23407E-03   -.95544    
  28  Prefactor     .91291        .20892        .23511E-03   -.95691    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.23808e-08
Minuit parameter uncertainties:
  1  2.14988e-05
  2  0.00022155
  3  62.0407
  4  6.73029e-06
  5  35.7836
  6  110.044
  7  1.2219e-06
  8  3.42758
  9  51.555
  10  3.3671e-05
  11  2.97412e-05
  12  47.0365
  13  4.15238
  14  20.2158
  15  9.35768e-06
  16  10.808
  17  20.2854
  18  0.000200798
  19  0.00506062
  20  2.19483e-05
  21  19.919
  22  8.09381e-05
  23  6.39637e-06
  24  4.68659e-05
  25  20.7206
  26  0.000311537
  27  0.220909
  28  0.2091
Done.

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

Extracting fit parameters...

4FGL J1330.2+7002
   Spectrum: PowerLaw
379    Prefactor:  2.515e+01  4.704e+01  1.000e-04  1.000e+04 ( 1.000e-14)
380        Index:  1.967e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
381        Scale:  2.478e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
732    Prefactor:  9.129e-01  2.091e-01  0.000e+00  1.000e+01 ( 1.000e+00)
733        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
734        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
731   Normalization:  9.262e-01  2.209e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.46
Ra Dec: 202.573 70.041
Photon Flux Upper Limit: 7.69e-08 ph cm-2 s-1
Energy Flux Upper Limit: 5.75e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/631537/likelihoodResults_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.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) = 5016.74078992
delta logL = 0.760778514938

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 5016.71626117
delta logL = 0.785307265849

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    3.5065       1.0000         .10000E-03   10000.    
     2 'Index     '    3.3941       1.0000          .0000       10.000    
     3 'Normalizat'    .84447       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .96316       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7350E+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=   5016.716     FROM MIGRAD    STATUS=FAILED        80 CALLS      291 TOTAL
                     EDM=   .33E-07    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     3.5059        96.169        .97090E-04   -.27064E-02
   2  Index         3.3947        3.6252        .32900E-02   -.82054E-03
   3  Normalizat    .84481        .22259        .24363E-03   -.56115E-03
   4  Prefactor     .96290        .20587        .22946E-03   -.50146E-03
                               ERR DEF=  .500    
 START SIMPLEX MINIMIZATION.    CONVERGENCE WHEN EDM .LT.   .20E-04
 SIMPLEX MINIMIZATION HAS CONVERGED.

 FCN=   5016.716     FROM SIMPLEX   STATUS=UNCHANGED     85 CALLS      376 TOTAL
                     EDM=   .19E-04    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     3.5059        96.169        .44227E-03   -.27064E-02
   2  Index         3.3947        3.6252        .21656E-02   -.82054E-03
   3  Normalizat    .84481        .22259        .34911E-03   -.56115E-03
   4  Prefactor     .96290        .20587        .40234E-03   -.50146E-03
                               ERR DEF=  .500    

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   5016.716     FROM MIGRAD    STATUS=CONVERGED     27 CALLS      403 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     3.5051        12.922        .38836E-05   -.28963E-02
   2  Index         3.3948        1.4313        .13160E-03   -.64844E-03
   3  Normalizat    .84481        .21918        .48725E-04   -.51718E-03
   4  Prefactor     .96290        .21137        .45893E-04   -.49797E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 3.50507
  Index      = 3.39483
  Normalizat = 0.844811
  Prefactor  = 0.962901
 **********
 **   18 **HESSE 
 **********

 FCN=   5016.716     FROM HESSE     STATUS=OK            23 CALLS      426 TOTAL
                     EDM=   .17E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     3.5051        12.483        .77672E-06   -1.5334    
   2  Index         3.3948        1.3835        .26320E-04   -.32682    
   3  Normalizat    .84481        .21880        .97450E-05   -.98427    
   4  Prefactor     .96290        .21110        .91786E-05   -.93977    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 1.73787e-09
Minuit parameter uncertainties:
  1  12.4919
  2  1.40401
  3  0.219026
  4  0.211276
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/631537': 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) = 5016.71625591
delta logL = 0.785312519605

Extracting fit parameters...

4FGL J1330.2+7002
   Spectrum: PowerLaw
379    Prefactor:  3.505e+00  1.249e+01  1.000e-04  1.000e+04 ( 1.000e-14)
380        Index:  3.395e+00  1.404e+00  0.000e+00  1.000e+01 (-1.000e+00)
381        Scale:  2.478e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
732    Prefactor:  9.629e-01  2.113e-01  0.000e+00  1.000e+01 ( 1.000e+00)
733        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
734        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
731   Normalization:  8.448e-01  2.190e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 2.16
Ra Dec: 202.573 70.041
Photon Index (Free Index): 3.39 +/- 1.40
Photon Flux (Free Index): 7.93e-08 +/- 7.26e-08
Energy Flux (Free Index): 1.36e-05 +/- 1.09e-05

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/631537/cmap_HighResolution_253843201_254102401_4FGL_J1330.2+7002_daily_bin56.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.75e-03', comment='SUCCESS', energy_flux2='1.36e-05', dlogl='7.85e-01', photon_flux2='7.93e-08', job_status='DONE', time_completed='2021-09-07 21:16:35.189566', photon_index_error2='1.40', photon_index2='3.39', ts='0.46', fit_tolerance='1e-08', GAL='0.91', photon_index_error='0.00', photon_flux_upper_limit='7.69e-08', energy_flux_error2='1.09e-05', EG='0.93', time_epoch_completed='1631074595.19', return_code='0', job_id='631537', GAL2='0.96', EG2='0.84', return_code2='0', photon_flux_error2='7.26e-08', ts2='2.16', photon_index='1.97' WHERE bin_id='56' AND source_name='4FGL J1330.2+7002' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Tue Sep  7 21:16:35 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0032>
Subject: Job 631537: <4FGL_J1330.2+7002_daily_bin56> in cluster <slac> Done

Job <4FGL_J1330.2+7002_daily_bin56> was submitted from host <rhel6-64k> by user <kocevski> in cluster <slac> at Tue Sep  7 21:00:30 2021
Job was executed on host(s) <bullet0032>, in queue <medium>, as user <kocevski> in cluster <slac> at Tue Sep  7 21:01:54 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Tue Sep  7 21:01:54 2021
Terminated at Tue Sep  7 21:16:35 2021
Results reported at Tue Sep  7 21:16:35 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1330.2+7002_daily_bin56 202.573 70.0406 253843201 254102401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1330.2+7002 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   867.00 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             362.61 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   881 sec.
    Turnaround time :                            965 sec.

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

