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


Performing analysis on: 4FGL_J1139.0+4033_daily_bin55
RA = 174.764, Dec = 40.5617
tmin = 253584001, tmax = 253843201
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='978771', job_status='RUN', time_executed='2021-09-04 06:45:11.070835', time_epoch_executed='1630763111.07' WHERE source_name='4FGL J1139.0+4033' and cadence='daily' and bin_id='55'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/978771

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/978771/ft1_4FGL_J1139.0+4033_daily_bin55.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/978771/ft1_4FGL_J1139.0+4033_daily_bin55.fits outfile=/scratch/kocevski/978771/ft1_filteredMKT_4FGL_J1139.0+4033_daily_bin55.fits ra=174.764 dec=40.5617 rad=12.0 tmin=253584001.0 tmax=253843201.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.45
user 1.24
sys 0.17

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.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/978771/ft1_filteredMKT_4FGL_J1139.0+4033_daily_bin55.fits evtable="EVENTS" outfile="/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.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.33
sys 0.15

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits" evtable="EVENTS" scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits sctable="SC_DATA" outfile=/scratch/kocevski/978771/ltcube_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.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/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits
.....................!
real 12.52
user 12.14
sys 0.30

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits evtable="EVENTS" scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits sctable="SC_DATA" expcube=/scratch/kocevski/978771/ltcube_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits outfile=/scratch/kocevski/978771/expmap_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.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/978771/ltcube_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits
.....................!
real 189.89
user 185.34
sys 4.18

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

Setting source of interest to:
4FGL J1139.0+4033 @ 174.764 40.5617

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits outfile=/scratch/kocevski/978771/cmap_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.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=174.764 yref=40.5617 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.53
user 0.34
sys 0.17

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits outfile=/scratch/kocevski/978771/cmap_HighResolution_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.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=174.764 yref=40.5617 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.36
sys 0.17

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits evtable="EVENTS" scfile=/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/978771/Model_4FGL_J1139.0+4033_daily_bin55.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/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits.....................!
real 45.05
user 43.78
sys 1.10

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits', '/scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits', expMap='/scratch/kocevski/978771/expmap_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits', expCube='/scratch/kocevski/978771/ltcube_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/978771/Model_4FGL_J1139.0+4033_daily_bin55.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1139.0+4033'

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  9.736e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.720e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/978771/ft1_filtered_4FGL_J1139.0+4033_daily_bin55.fits
Spacecraft file(s): /scratch/kocevski/978771/ft2_4FGL_J1139.0+4033_daily_bin55.fits
Exposure map: /scratch/kocevski/978771/expmap_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits
Exposure cube: /scratch/kocevski/978771/ltcube_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/978771/Model_4FGL_J1139.0+4033_daily_bin55.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) = 4869.91856017

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    49.212       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     3 'norm      '    .85497       1.0000         .10000E-03   10000.    
     4 'Prefactor '    4.8641       1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     7 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     8 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    4.0947       1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10054E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    1.1283       1.0000         .10000E-03   10000.    
    12 'norm      '    2.1413       1.0000         .10000E-03   10000.    
    13 'Prefactor '    8.3965       1.0000         .10000E-03   10000.    
    14 'Prefactor '    1.6980       1.0000         .10000E-03   10000.    
    15 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    16 'norm      '    1.4727       1.0000         .10000E-03   10000.    
    17 'norm      '    9.6635       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10026E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    1.2437       1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .92370       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .85456       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6960E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   4869.913     FROM MIGRAD    STATUS=CONVERGED    583 CALLS     2890 TOTAL
                     EDM=   .76E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  4.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     49.211        41.376       -.19260E-06   -.22601E-04
   2  Prefactor     .10000E-03    38.383       -.20879E-05** at limit **
   3  norm          .85496        .28993       -.59378E-07   -.71392E-06
   4  Prefactor     4.8650        12.436        .54736E-05   -.41113E-03
   5  Prefactor     .10000E-03    5.7706       -.14003E-06** at limit **
   6  Prefactor     .10001E-03    29.833       -.33206E-05** at limit **
   7  norm          .10000E-03    9.1540       -.60481E-06** at limit **
   8  norm          .10000E-03    14.638       -.61340E-06** at limit **
   9  Prefactor     4.0928        2.9714       -.14271E-06    .87179E-04
  10  Prefactor     .10001E-03    90.147       -.45702E-05** at limit **
  11  Prefactor     1.1207        22.044       -.10192E-05    .13637E-03
  12  norm          2.1408        1.9284       -.16609E-07    .65736E-04
  13  Prefactor     8.4004        14.510        .93993E-07    .16763E-03
  14  Prefactor     1.6978        4.0336        .41223E-06   -.72035E-04
  15  Prefactor     .10000E-03    27.859       -.13866E-05** at limit **
  16  norm          1.4727        1.0241        .49996E-07   -.84599E-04
  17  norm          9.6637        8.7617       -.32124E-06    .11960E-03
  18  Prefactor     .10002E-03    47.198        .73425E-05** at limit **
  19  Prefactor     1.2435        3.0817        .52287E-06   -.13577E-03
  20  Prefactor     .10001E-03    23.347        .35594E-05** at limit **
  21  Prefactor     .10000E-03    7.0028       -.17661E-07** at limit **
  22  Prefactor     .10000E-03    10.476        .40417E-06** at limit **
  23  Prefactor     .10000E-03    3.4036        .25294E-07** at limit **
  24  Normalizat    .92369        .17230       -.53381E-06    .47196E-05
  25  Prefactor     .85458        .20106       -.26070E-06   -.89198E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 49.2108
  Prefactor  = 0.000100002
  norm       = 0.854958
  Prefactor  = 4.86501
  Prefactor  = 0.0001
  Prefactor  = 0.000100005
  norm       = 0.0001
  norm       = 0.0001
  Prefactor  = 4.09283
  Prefactor  = 0.000100008
  Prefactor  = 1.12068
  norm       = 2.1408
  Prefactor  = 8.40037
  Prefactor  = 1.69779
  Prefactor  = 0.000100001
  norm       = 1.47274
  norm       = 9.66366
  Prefactor  = 0.000100022
  Prefactor  = 1.24354
  Prefactor  = 0.000100006
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.923693
  Prefactor  = 0.854581
 **********
 **   18 **HESSE 
 **********

 FCN=   4869.913     FROM HESSE     STATUS=OK           427 CALLS     3317 TOTAL
                     EDM=   .32E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     49.211        41.391        .57164E-04   -1.4304    
   2  Prefactor     .10000E-03    38.718        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  norm          .85496        .29077        .20762E-04   -1.5523    
   4  Prefactor     4.8650        13.174        .91195E-03   -1.5267    
   5  Prefactor     .10000E-03    5.7780        .16374E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  Prefactor     .10001E-03    30.636        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  norm          .10000E-03    9.2493        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  norm          .10000E-03    14.666        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     4.0928        2.9460        .93956E-04   -1.5303    
  10  Prefactor     .10001E-03    91.974        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     1.1207        202.00        .46811E-02   -1.5496    
  12  norm          2.1408        1.9197        .87130E-04   -1.5415    
  13  Prefactor     8.4004        19.554        .13835E-03   -1.5128    
  14  Prefactor     1.6978        3.9775        .20360E-03   -1.5447    
  15  Prefactor     .10000E-03    28.094        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  16  norm          1.4727        1.0150        .56037E-04   -1.5465    
  17  norm          9.6637        8.7713        .64455E-03   -1.5086    
  18  Prefactor     .10002E-03    51.038        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     1.2435        3.0665        .18400E-03   -1.5485    
  20  Prefactor     .10001E-03    24.271        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     .10000E-03    7.0053        .18032E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  22  Prefactor     .10000E-03    10.493        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    3.4205        .12573E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .92369        .19935        .22177E-03   -.95633    
  25  Prefactor     .85458        .23194        .27592E-03   -.97747    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 3.19952e-09
Minuit parameter uncertainties:
  1  41.4152
  2  0.00055383
  3  0.290773
  4  13.1815
  5  1.311e-05
  6  0.000786635
  7  7.13066e-05
  8  0.000100596
  9  2.94614
  10  0.00175832
  11  30.1942
  12  1.91971
  13  19.5689
  14  3.9781
  15  0.000308953
  16  1.015
  17  8.77251
  18  0.00210658
  19  3.06693
  20  0.00074825
  21  2.00534e-06
  22  5.18729e-05
  23  1.34747e-06
  24  0.199511
  25  0.232211
Done.

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

Extracting fit parameters...

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  1.000e-04  3.090e-04  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.720e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
693    Prefactor:  8.546e-01  2.322e-01  0.000e+00  1.000e+01 ( 1.000e+00)
694        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
695        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
692   Normalization:  9.237e-01  1.995e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 174.764 40.562
Photon Flux Upper Limit: 7.80e-08 ph cm-2 s-1
Energy Flux Upper Limit: 6.14e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/978771/likelihoodResults_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.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) = 4869.91340152
delta logL = -0.000169557398294

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 4869.91323347
delta logL = -1.50609594129e-06

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10012E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    3.2388       1.0000          .0000       10.000    
     3 'Normalizat'    .92369       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .85458       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6960E+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.

 FCN=   4869.913     FROM MIGRAD    STATUS=CONVERGED    106 CALLS      291 TOTAL
                     EDM=   .88E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10007E-03    74.395        .18142E-01** at limit **
   2  Index         2.3381        5.0201        .50000        .37671E-06
   3  Normalizat    .92369        .62818E-02    .22177E-03    .14885E-02
   4  Prefactor     .85458        .75874E-02    .27592E-03    .12072E-02
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100068
  Index      = 2.33814
  Normalizat = 0.923695
  Prefactor  = 0.854584
 **********
 **   18 **HESSE 
 **********

 FCN=   4869.913     FROM HESSE     STATUS=NOT POSDEF    27 CALLS      318 TOTAL
                     EDM=   .49E-08    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10007E-03    406.17        .36285E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.3381        5.6929        .50000       -.56140    
   3  Normalizat    .92369        .14823E-01    .44354E-04   -.95632    
   4  Prefactor     .85458        .17904E-01    .55184E-04   -.97747    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 4.92649e-09
Minuit parameter uncertainties:
  1  0.0106139
  2  993.803
  3  0.014823
  4  0.0179039
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/978771': 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) = 4869.91323167
delta logL = 2.90500793199e-07

Extracting fit parameters...

4FGL J1139.0+4033
   Spectrum: PowerLaw
341    Prefactor:  1.001e-04  1.061e-02  1.000e-04  1.000e+04 ( 1.000e-13)
342        Index:  2.338e+00  9.938e+02  0.000e+00  1.000e+01 (-1.000e+00)
343        Scale:  6.779e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
693    Prefactor:  8.546e-01  1.790e-02  0.000e+00  1.000e+01 ( 1.000e+00)
694        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
695        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
692   Normalization:  9.237e-01  1.482e-02  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 174.764 40.562

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/978771/cmap_HighResolution_253584001_253843201_4FGL_J1139.0+4033_daily_bin55.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='6.14e-03', job_status='DONE', photon_flux_upper_limit='7.80e-08', time_completed='2021-09-04 06:56:44.024948', job_id='978771', GAL2='0.85', fit_tolerance='1e-08', EG2='0.92', EG='0.92', time_epoch_completed='1630763804.03', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.85', dlogl='2.91e-07', ts2='-0.00', photon_index_error='0.00', photon_index='2.72' WHERE bin_id='55' AND source_name='4FGL J1139.0+4033' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 06:56:44 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0123>
Subject: Job 978771: <4FGL_J1139.0+4033_daily_bin55> in cluster <slac> Done

Job <4FGL_J1139.0+4033_daily_bin55> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Sat Sep  4 06:41:20 2021
Job was executed on host(s) <bullet0123>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 06:41:22 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 06:41:22 2021
Terminated at Sat Sep  4 06:56:45 2021
Results reported at Sat Sep  4 06:56:45 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1139.0+4033_daily_bin55 174.764 40.5617 253584001 253843201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1139.0+4033 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   685.26 sec.
    Max Memory :                                 1095 MB
    Average Memory :                             264.67 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   922 sec.
    Turnaround time :                            925 sec.

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

