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


Performing analysis on: 4FGL_J1204.8+0407_daily_bin1570
RA = 181.203, Dec = 4.12
tmin = 646272001, tmax = 646531201
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='312205', job_status='RUN', time_executed='2021-09-04 23:23:06.287919', time_epoch_executed='1630822986.29' WHERE source_name='4FGL J1204.8+0407' and cadence='daily' and bin_id='1570'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/312205

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

Retrieving the FT1 file...

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

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

Retrieving 47 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/312205/ft1_4FGL_J1204.8+0407_daily_bin1570.fits


Retrieving the FT1 file...

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

Retrieving 47 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/312205/ft1_4FGL_J1204.8+0407_daily_bin1570.fits outfile=/scratch/kocevski/312205/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1570.fits ra=181.203 dec=4.12 rad=12.0 tmin=646272001.0 tmax=646531201.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.22
user 2.92
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.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/312205/ft1_filteredMKT_4FGL_J1204.8+0407_daily_bin1570.fits evtable="EVENTS" outfile="/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.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.43
user 0.23
sys 0.16

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits" evtable="EVENTS" scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits sctable="SC_DATA" outfile=/scratch/kocevski/312205/ltcube_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.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/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits
.....................!
real 8.63
user 8.34
sys 0.27

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits evtable="EVENTS" scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits sctable="SC_DATA" expcube=/scratch/kocevski/312205/ltcube_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits outfile=/scratch/kocevski/312205/expmap_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.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/312205/ltcube_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits
.....................!
real 140.54
user 137.08
sys 3.14

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

Setting source of interest to:
4FGL J1204.8+0407 @ 181.203 4.12

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits outfile=/scratch/kocevski/312205/cmap_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.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=181.203 yref=4.12 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.44
user 0.28
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits outfile=/scratch/kocevski/312205/cmap_HighResolution_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.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=181.203 yref=4.12 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.44
user 0.30
sys 0.13

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits evtable="EVENTS" scfile=/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/312205/Model_4FGL_J1204.8+0407_daily_bin1570.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/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits.....................!
real 44.48
user 43.46
sys 0.93

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits', '/scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits', expMap='/scratch/kocevski/312205/expmap_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits', expCube='/scratch/kocevski/312205/ltcube_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/312205/Model_4FGL_J1204.8+0407_daily_bin1570.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1204.8+0407'

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  3.692e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  2.578e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/312205/ft1_filtered_4FGL_J1204.8+0407_daily_bin1570.fits
Spacecraft file(s): /scratch/kocevski/312205/ft2_4FGL_J1204.8+0407_daily_bin1570.fits
Exposure map: /scratch/kocevski/312205/expmap_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits
Exposure cube: /scratch/kocevski/312205/ltcube_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/312205/Model_4FGL_J1204.8+0407_daily_bin1570.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) = 6730.07355738

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .92986       1.0000         .10000E-03   10000.    
     2 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    7.2552       1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10242E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    4.5566       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10003E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10024E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10458E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .29253E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    29.581       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10011E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    .11442E-03   1.0000         .10000E-03   10000.    
    13 'Prefactor '    .49346E-03   1.0000         .10000E-03   10000.    
    14 'Prefactor '    .10005E-03   1.0000         .10000E-03   10000.    
    15 'Prefactor '    5.6783       1.0000         .10000E-03   10000.    
    16 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    .77246       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10007E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    10.154       1.0000         .10000E-03   10000.    
    20 'Prefactor '    58.565       1.0000         .10000E-03   10000.    
    21 'norm      '    2.6450       1.0000         .10000E-03   10000.    
    22 'Prefactor '    16.057       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .18326       1.0000         .10000E-03   10000.    
    24 'Prefactor '    6.7028       1.0000         .10000E-03   10000.    
    25 'norm      '    3.3379       1.0000         .10000E-03   10000.    
    26 'Prefactor '    .10001E-03   1.0000         .10000E-03   10000.    
    27 'Prefactor '    3.0679       1.0000         .10000E-03   10000.    
    28 'Normalizat'    1.2030       1.0000         .10000E-01   10.000    
    29 'Prefactor '    .78916       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   6730.058     FROM MIGRAD    STATUS=CONVERGED    787 CALLS     3786 TOTAL
                     EDM=   .83E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  5.6%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .92892        1.4700       -.48371E-06   -.52354E-03
   2  Prefactor     .10000E-03    41.724       -.24367E-06** at limit **
   3  Prefactor     7.2548        12.562        .10231E-06    .11078E-03
   4  Prefactor     .10000E-03    126.96        .23090E-05** at limit **
   5  Prefactor     4.5562        8.0435       -.12439E-06    .14987E-03
   6  Prefactor     .10000E-03    13.849       -.26416E-06** at limit **
   7  Prefactor     .10000E-03    6.6830       -.27772E-07** at limit **
   8  Prefactor     .10000E-03    19.271       -.73918E-07** at limit **
   9  Prefactor     .10001E-03    24.001       -.80837E-05** at limit **
  10  Prefactor     29.549        90.502       -.25331E-06    .14179E-04
  11  Prefactor     .10000E-03    13.716        .16912E-06** at limit **
  12  Prefactor     .10000E-03    135.39       -.22115E-05** at limit **
  13  Prefactor     .10005E-03    54.326        .11198E-04** at limit **
  14  Prefactor     .10000E-03    14.459        .18943E-06** at limit **
  15  Prefactor     5.6790        6.8404        .15086E-06    .23738E-03
  16  norm          .10000E-03    .69582       -.23058E-07** at limit **
  17  norm          .77501        3.3278        .82259E-06    .86644E-03
  18  Prefactor     .10000E-03    7.3318       -.57473E-09** at limit **
  19  norm          10.161        23.034        .56300E-06    .48550E-04
  20  Prefactor     58.555        61.238       -.18469E-06   -.36332E-05
  21  norm          2.6452        .69358        .56606E-07    .22110E-02
  22  Prefactor     16.081        12.560        .15273E-07   -.23330E-03
  23  Prefactor     .10844E-03    26.509       -.12396E-05** at limit **
  24  Prefactor     6.7029        7.7593       -.16857E-07    .20571E-03
  25  norm          3.3382        1.7544        .21444E-07    .50390E-03
  26  Prefactor     .10000E-03    3.2950       -.45307E-07** at limit **
  27  Prefactor     3.0597        52.193       -.53846E-06    .29617E-04
  28  Normalizat    1.2029        .18993        .34177E-06    .72188E-03
  29  Prefactor     .78925        .14789        .77323E-06    .78126E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.928919
  Prefactor  = 0.0001
  Prefactor  = 7.25485
  Prefactor  = 0.0001
  Prefactor  = 4.55622
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100013
  Prefactor  = 29.5495
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 0.000100048
  Prefactor  = 0.0001
  Prefactor  = 5.67902
  norm       = 0.0001
  norm       = 0.775008
  Prefactor  = 0.0001
  norm       = 10.1608
  Prefactor  = 58.5552
  norm       = 2.64522
  Prefactor  = 16.0813
  Prefactor  = 0.000108438
  Prefactor  = 6.7029
  norm       = 3.33815
  Prefactor  = 0.0001
  Prefactor  = 3.05974
  Normalizat = 1.20288
  Prefactor  = 0.789253
 **********
 **   18 **HESSE 
 **********

 FCN=   6730.058     FROM HESSE     STATUS=OK           565 CALLS     4351 TOTAL
                     EDM=   .29E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .92892        1.3676        .12734E-02   -1.5515    
   2  Prefactor     .10000E-03    42.459        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     7.2548        12.557        .14891E-03   -1.5169    
   4  Prefactor     .10000E-03    127.21        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     4.5562        8.0055        .18858E-03   -1.5281    
   6  Prefactor     .10000E-03    13.859        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     .10000E-03    6.8277        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     .10000E-03    19.383        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10001E-03    49.493        .38879E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     29.549        90.418        .73665E-04   -1.4620    
  11  Prefactor     .10000E-03    13.722        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     .10000E-03    137.19        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  13  Prefactor     .10005E-03    100.99        .56365E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  Prefactor     .10000E-03    14.486        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  Prefactor     5.6790        6.7824        .16857E-03   -1.5231    
  16  norm          .10000E-03    .70551        .66750E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          .77501        4.8332        .22478E-02   -1.5532    
  18  Prefactor     .10000E-03    7.3331        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          10.161        22.896        .12575E-03   -1.5070    
  20  Prefactor     58.555        61.257        .52424E-04   -1.4176    
  21  norm          2.6452        .68644        .29837E-04   -1.5383    
  22  Prefactor     16.081        12.659        .99952E-04   -1.4906    
  23  Prefactor     .10844E-03    29.145        .12687       -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Prefactor     6.7029        7.7615        .15499E-03   -1.5190    
  25  norm          3.3382        1.7441        .74132E-04   -1.5343    
  26  Prefactor     .10000E-03    3.3039        .14543E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  27  Prefactor     3.0597        52.230        .23159E-03   -1.5358    
  28  Normalizat    1.2029        .22159        .25110E-03   -.86514    
  29  Prefactor     .78925        .17484        .24894E-03   -1.0013    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.93461e-09
Minuit parameter uncertainties:
  1  1.36765
  2  0.000150693
  3  12.5617
  4  0.000505002
  5  8.00733
  6  2.3665e-05
  7  1.86507e-06
  8  4.60632e-05
  9  0.00159274
  10  90.8414
  11  1.55735e-05
  12  0.000478068
  13  0.00441552
  14  2.34971e-06
  15  6.78334
  16  3.04267e-06
  17  3.87103
  18  3.63148e-07
  19  22.9154
  20  61.323
  21  0.686445
  22  12.6607
  23  0.0313793
  24  7.76264
  25  1.74417
  26  1.59123e-05
  27  25.3086
  28  0.22176
  29  0.174966
Done.

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

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  1.000e-04  4.781e-04  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  2.578e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  7.893e-01  1.750e-01  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  1.203e+00  2.218e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 181.203 4.120
Photon Flux Upper Limit: 9.53e-08 ph cm-2 s-1
Energy Flux Upper Limit: 7.45e-03 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/312205/likelihoodResults_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.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) = 6730.05801215
delta logL = -3.4600179788e-05

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 6730.05797785
delta logL = -2.99562998407e-07

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10329E-03   1.0000         .10000E-03   10000.    
     2 'Index     '    2.7469       1.0000          .0000       10.000    
     3 'Normalizat'    1.2029       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .78926       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .6140E+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=   6730.058     FROM MIGRAD    STATUS=CONVERGED    102 CALLS      301 TOTAL
                     EDM=   .93E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10911E-03    .58626        .18142    ** at limit **
   2  Index         2.6081        6.2615        .50000        .65004E-05
   3  Normalizat    1.2029        .80799E-03    .25110E-03    .12270E-04
   4  Prefactor     .78925        .66684E-03    .24894E-03    .95447E-05
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000109107
  Index      = 2.6081
  Normalizat = 1.20288
  Prefactor  = 0.789251
 **********
 **   18 **HESSE 
 **********

 FCN=   6730.058     FROM HESSE     STATUS=NOT POSDEF    31 CALLS      332 TOTAL
                     EDM=   .25E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10911E-03    162.28        .68828E-02   -1.5707    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.6081        8.4537        .50000       -.49881    
   3  Normalizat    1.2029        .52190E-02    .10044E-04   -.86514    
   4  Prefactor     .78925        .43073E-02    .99576E-05   -1.0013    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 2.46344e-10
Minuit parameter uncertainties:
  1  0.0770946
  2  213.566
  3  0.00521899
  4  0.00430727
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/312205': 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) = 6730.05797762
delta logL = -7.42038537282e-08

Extracting fit parameters...

4FGL J1204.8+0407
   Spectrum: PowerLaw
316    Prefactor:  1.091e-04  7.709e-02  1.000e-04  1.000e+04 ( 1.000e-13)
317        Index:  2.608e+00  2.136e+02  0.000e+00  1.000e+01 (-1.000e+00)
318        Scale:  7.480e+02  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
611    Prefactor:  7.893e-01  4.307e-03  0.000e+00  1.000e+01 ( 1.000e+00)
612        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
613        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
610   Normalization:  1.203e+00  5.219e-03  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 181.203 4.120

Creating a high resolution counts map...
INFO: Auto-setting vmin to -2.500e-04 [aplpy.core]
INFO: Auto-setting vmax to  2.775e-03 [aplpy.core]
Saving /scratch/kocevski/312205/cmap_HighResolution_646272001_646531201_4FGL_J1204.8+0407_daily_bin1570.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='7.45e-03', job_status='DONE', photon_flux_upper_limit='9.53e-08', time_completed='2021-09-04 23:34:28.849845', job_id='312205', GAL2='0.79', fit_tolerance='1e-08', EG2='1.20', EG='1.20', time_epoch_completed='1630823668.85', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.79', dlogl='-7.42e-08', ts2='-0.00', photon_index_error='0.00', photon_index='2.58' WHERE bin_id='1570' AND source_name='4FGL J1204.8+0407' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Sat Sep  4 23:34:28 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0071>
Subject: Job 312205: <4FGL_J1204.8+0407_daily_bin1570> in cluster <slac> Done

Job <4FGL_J1204.8+0407_daily_bin1570> was submitted from host <rhel6-64j> by user <kocevski> in cluster <slac> at Sat Sep  4 23:20:56 2021
Job was executed on host(s) <bullet0071>, in queue <medium>, as user <kocevski> in cluster <slac> at Sat Sep  4 23:20:58 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Sat Sep  4 23:20:58 2021
Terminated at Sat Sep  4 23:34:29 2021
Results reported at Sat Sep  4 23:34:29 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J1204.8+0407_daily_bin1570 181.203 4.12 646272001 646531201 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J1204.8+0407 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   683.42 sec.
    Max Memory :                                 1094 MB
    Average Memory :                             250.00 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   811 sec.
    Turnaround time :                            813 sec.

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

