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


Performing analysis on: 4FGL_J2358.3+3830_daily_bin1206
RA = 359.588, Dec = 38.5097
tmin = 551923201, tmax = 552182401
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='224651', job_status='RUN', time_executed='2021-09-30 11:02:43.090519', time_epoch_executed='1633024963.09' WHERE source_name='4FGL J2358.3+3830' and cadence='daily' and bin_id='1206'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/224651

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

Retrieving the FT1 file...

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

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

Retrieving 46 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/224651/ft1_4FGL_J2358.3+3830_daily_bin1206.fits


Retrieving the FT1 file...

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

Retrieving 46 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/224651/ft1_4FGL_J2358.3+3830_daily_bin1206.fits outfile=/scratch/kocevski/224651/ft1_filteredMKT_4FGL_J2358.3+3830_daily_bin1206.fits ra=359.588 dec=38.5097 rad=12.0 tmin=551923201.0 tmax=552182401.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.67
user 3.47
sys 0.18

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.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/224651/ft1_filteredMKT_4FGL_J2358.3+3830_daily_bin1206.fits evtable="EVENTS" outfile="/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.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.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits" evtable="EVENTS" scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits sctable="SC_DATA" outfile=/scratch/kocevski/224651/ltcube_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.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/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits
.....................!
real 12.52
user 12.14
sys 0.36

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits evtable="EVENTS" scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits sctable="SC_DATA" expcube=/scratch/kocevski/224651/ltcube_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits outfile=/scratch/kocevski/224651/expmap_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.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/224651/ltcube_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits
.....................!
real 193.52
user 187.70
sys 5.46

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
Extended source FHES J2304.0+5406 in ROI with RadialGaussian spatial model.
Added 154 point sources and 1 extended sources
If using unbinned likelihood you will need to rerun gtdiffrsp for the extended sources or rerun the makeModel function with optional argument psForce=True

Setting source of interest to:
4FGL J2358.3+3830 @ 359.588 38.5097

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits outfile=/scratch/kocevski/224651/cmap_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.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=359.588 yref=38.5097 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.51
user 0.35
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits outfile=/scratch/kocevski/224651/cmap_HighResolution_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.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=359.588 yref=38.5097 axisrot=0.0 rafield="RA" decfield="DEC" proj="AIT" hpx_ordering_scheme="RING" hpx_order=3 hpx_ebin=yes hpx_region="" evtable="EVENTS" sctable="SC_DATA" efield="ENERGY" tfield="TIME" chatter=2 clobber=yes debug=no gui=no mode="ql"

WARNING: version mismatch between CFITSIO header (v3.43) and linked library (v3.41).

This is gtbin version HEAD
real 0.54
user 0.37
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits evtable="EVENTS" scfile=/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/224651/Model_4FGL_J2358.3+3830_daily_bin1206.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 FHES J2304.0+5406
adding source GAL_V02
Working on...
/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits.....................!
real 34.11
user 32.82
sys 1.21

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits', '/scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits', expMap='/scratch/kocevski/224651/expmap_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits', expCube='/scratch/kocevski/224651/ltcube_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/224651/Model_4FGL_J2358.3+3830_daily_bin1206.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2358.3+3830'

4FGL J2358.3+3830
   Spectrum: PowerLaw
488    Prefactor:  8.894e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
489        Index:  2.175e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
490        Scale:  2.145e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/224651/ft1_filtered_4FGL_J2358.3+3830_daily_bin1206.fits
Spacecraft file(s): /scratch/kocevski/224651/ft2_4FGL_J2358.3+3830_daily_bin1206.fits
Exposure map: /scratch/kocevski/224651/expmap_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits
Exposure cube: /scratch/kocevski/224651/ltcube_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/224651/Model_4FGL_J2358.3+3830_daily_bin1206.xml
Optimizer: MINUIT
Statistic: UNBINNED

Performing an iterative likelihood fit...

Fit tolerance = 1

Performing likelihood fit...
Done.

MINUIT Return Code (Fixed Index): 102
logL (Fixed Index) = 2282.86477333

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .75627E-02   1.0000         .10000E-03   10000.    
     2 'Prefactor '    69.049       1.0000         .10000E-03   10000.    
     3 'norm      '    .10013E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    24.869       1.0000         .10000E-03   10000.    
     6 'Prefactor '    .10127E-03   1.0000         .10000E-03   10000.    
     7 'Prefactor '    83.925       1.0000         .10000E-03   10000.    
     8 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10026E-03   1.0000         .10000E-03   10000.    
    10 'norm      '    .10000E-03   1.0000         .10000E-03   10000.    
    11 'Prefactor '    30.054       1.0000         .10000E-03   10000.    
    12 'Prefactor '    74.084       1.0000         .10000E-03   10000.    
    13 'norm      '    7.7917       1.0000         .10000E-03   10000.    
    14 'Prefactor '    12.097       1.0000         .10000E-03   10000.    
    15 'norm      '    16.563       1.0000         .10000E-03   10000.    
    16 'norm      '    .10011E-03   1.0000         .10000E-03   10000.    
    17 'Prefactor '    .10057E-03   1.0000         .10000E-03   10000.    
    18 'norm      '    .10193E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10013E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    732.77       1.0000         .10000E-03   10000.    
    21 'Prefactor '    167.05       1.0000         .10000E-03   10000.    
    22 'Prefactor '    166.21       1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10356E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .65625       1.0000         .10000E-01   10.000    
    25 'Prefactor '    .93063       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5050E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2282.330     FROM MIGRAD    STATUS=CONVERGED    537 CALLS     2990 TOTAL
                     EDM=   .27E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  1.2%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10018E-03    1580.7       -.13523E-03** at limit **
   2  Prefactor     68.477        520.06       -.37253E-04   -.80061E-05
   3  norm          .10000E-03    41.934        .52792E-07** at limit **
   4  Prefactor     .10000E-03    9.9248       -.65020E-06** at limit **
   5  Prefactor     24.866        17.598        .72011E-07    .56634E-04
   6  Prefactor     .10000E-03    13.780       -.38560E-05** at limit **
   7  Prefactor     83.863        223.34        .47795E-05    .47166E-05
   8  Prefactor     .10000E-03    30.702       -.50012E-07** at limit **
   9  Prefactor     .10000E-03    103.25       -.83319E-06** at limit **
  10  norm          .10000E-03    1.6277        .25204E-06** at limit **
  11  Prefactor     30.052        19.414       -.72556E-07    .26998E-04
  12  Prefactor     73.958        137.32       -.20891E-05    .13143E-05
  13  norm          7.7919        5.3583        .51504E-06    .18117E-03
  14  Prefactor     12.115        123.37       -.67862E-05   -.14568E-07
  15  norm          16.561        11.817       -.41971E-06    .20253E-04
  16  norm          .10000E-03    31.132       -.55124E-06** at limit **
  17  Prefactor     .10000E-03    105.67        .29814E-05** at limit **
  18  norm          .10000E-03    20.198        .16344E-06** at limit **
  19  Prefactor     .10000E-03    21.288        .54016E-06** at limit **
  20  Prefactor     731.19        835.30       -.24548E-05   -.14703E-04
  21  Prefactor     167.10        102.20        .13251E-05    .34108E-04
  22  Prefactor     166.26        196.37        .15990E-05    .30410E-04
  23  Prefactor     .10000E-03    60.307       -.35070E-06** at limit **
  24  Normalizat    .65521        .47680       -.22015E-04    .41840E-04
  25  Prefactor     .93123        .23649        .94159E-05   -.16288E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100175
  Prefactor  = 68.4766
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 24.8658
  Prefactor  = 0.0001
  Prefactor  = 83.863
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 30.0516
  Prefactor  = 73.9581
  norm       = 7.79191
  Prefactor  = 12.115
  norm       = 16.5606
  norm       = 0.0001
  Prefactor  = 0.000100001
  norm       = 0.0001
  Prefactor  = 0.0001
  Prefactor  = 731.191
  Prefactor  = 167.097
  Prefactor  = 166.256
  Prefactor  = 0.0001
  Normalizat = 0.655206
  Prefactor  = 0.931227
 **********
 **   18 **HESSE 
 **********

 FCN=   2282.330     FROM HESSE     STATUS=OK           419 CALLS     3409 TOTAL
                     EDM=   .65E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10018E-03    1612.4        .18572E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     68.477        518.92        .24153E-03   -1.4051    
   3  norm          .10000E-03    41.985        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    9.9303        .14700E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     24.866        17.582        .80327E-04   -1.4710    
   6  Prefactor     .10000E-03    13.852        .17346E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   7  Prefactor     83.863        223.48        .21924E-03   -1.3874    
   8  Prefactor     .10000E-03    30.710        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    103.32        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  norm          .10000E-03    1.6364        .59517E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     30.052        19.413        .73084E-04   -1.4611    
  12  Prefactor     73.958        137.43        .23323E-03   -1.3986    
  13  norm          7.7919        5.3555        .41860E-03   -1.5150    
  14  Prefactor     12.115        121.84        .11517E-03   -1.5012    
  15  norm          16.561        11.808        .98411E-04   -1.4894    
  16  norm          .10000E-03    31.145        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  Prefactor     .10000E-03    106.57        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  norm          .10000E-03    20.391        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    21.296        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     731.19        839.88        .76749E-04   -1.0232    
  21  Prefactor     167.10        102.11        .15605E-03   -1.3115    
  22  Prefactor     166.26        195.86        .15644E-03   -1.3122    
  23  Prefactor     .10000E-03    60.394        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .65521        .50478        .44651E-03   -1.0569    
  25  Prefactor     .93123        .25499        .19482E-03   -.95058    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 6.53594e-10
Minuit parameter uncertainties:
  1  0.0346093
  2  381.714
  3  6.9311e-06
  4  8.98806e-06
  5  17.5852
  6  9.94697e-05
  7  225.781
  8  2.40028e-05
  9  5.46652e-05
  10  6.30744e-06
  11  19.4168
  12  138.025
  13  5.35582
  14  77.0441
  15  11.8099
  16  1.30901e-05
  17  0.000474895
  18  7.4025e-05
  19  2.83835e-05
  20  855.182
  21  102.222
  22  196.632
  23  5.57456e-05
  24  0.508404
  25  0.255319
Done.

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

Extracting fit parameters...

4FGL J2358.3+3830
   Spectrum: PowerLaw
488    Prefactor:  1.663e+02  1.966e+02  1.000e-04  1.000e+04 ( 1.000e-14)
489        Index:  2.175e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
490        Scale:  2.145e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
502    Prefactor:  9.312e-01  2.553e-01  0.000e+00  1.000e+01 ( 1.000e+00)
503        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
504        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
497   Normalization:  6.552e-01  5.084e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 0.95
Ra Dec: 359.588 38.510
Photon Flux Upper Limit: 4.08e-07 ph cm-2 s-1
Energy Flux Upper Limit: 3.10e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/224651/likelihoodResults_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.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) = 2281.93836096
delta logL = 0.391779437513

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2281.93509854
delta logL = 0.395041854118

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    73.189       1.0000         .10000E-03   10000.    
     2 'Index     '    2.8463       1.0000          .0000       10.000    
     3 'Normalizat'    .60204       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .93833       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5050E+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=   2281.935     FROM MIGRAD    STATUS=CONVERGED     82 CALLS      289 TOTAL
                     EDM=   .44E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     73.160        150.38        .46929E-04    .33649E-04
   2  Index         2.8463        .91346        .33702E-02    .15990E-04
   3  Normalizat    .60172        .47504        .46355E-03   -.80897E-04
   4  Prefactor     .93859        .24648        .19374E-03   -.38357E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 73.1605
  Index      = 2.8463
  Normalizat = 0.601724
  Prefactor  = 0.938594
 **********
 **   18 **HESSE 
 **********

 FCN=   2281.935     FROM HESSE     STATUS=OK            25 CALLS      314 TOTAL
                     EDM=   .45E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     73.160        127.78        .93858E-05   -1.3995    
   2  Index         2.8463        .77596        .13481E-03   -.44531    
   3  Normalizat    .60172        .47385        .18542E-04   -1.0791    
   4  Prefactor     .93859        .24584        .38748E-04   -.94805    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 4.49431e-10
Minuit parameter uncertainties:
  1  128.263
  2  0.779837
  3  0.477096
  4  0.246133
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/224651': 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) = 2281.93509784
delta logL = 0.39504254834

Extracting fit parameters...

4FGL J2358.3+3830
   Spectrum: PowerLaw
488    Prefactor:  7.316e+01  1.283e+02  1.000e-04  1.000e+04 ( 1.000e-14)
489        Index:  2.846e+00  7.798e-01  0.000e+00  1.000e+01 (-1.000e+00)
490        Scale:  2.145e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
502    Prefactor:  9.386e-01  2.461e-01  0.000e+00  1.000e+01 ( 1.000e+00)
503        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
504        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
497   Normalization:  6.017e-01  4.771e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 1.72
Ra Dec: 359.588 38.510
Photon Index (Free Index): 2.85 +/- 0.78
Photon Flux (Free Index): 2.44e-07 +/- 2.39e-07
Energy Flux (Free Index): 5.31e-05 +/- 4.64e-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/224651/cmap_HighResolution_551923201_552182401_4FGL_J2358.3+3830_daily_bin1206.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.10e-02', comment='SUCCESS', energy_flux2='5.31e-05', dlogl='3.95e-01', photon_flux2='2.44e-07', job_status='DONE', time_completed='2021-09-30 11:12:48.629377', photon_index_error2='0.78', photon_index2='2.85', ts='0.95', fit_tolerance='1e-08', GAL='0.93', photon_index_error='0.00', photon_flux_upper_limit='4.08e-07', energy_flux_error2='4.64e-05', EG='0.66', time_epoch_completed='1633025568.63', return_code='0', job_id='224651', GAL2='0.94', EG2='0.60', return_code2='0', photon_flux_error2='2.39e-07', ts2='1.72', photon_index='2.17' WHERE bin_id='1206' AND source_name='4FGL J2358.3+3830' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 11:12:48 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0106>
Subject: Job 224651: <4FGL_J2358.3+3830_daily_bin1206> in cluster <slac> Done

Job <4FGL_J2358.3+3830_daily_bin1206> was submitted from host <rhel6-64q> by user <kocevski> in cluster <slac> at Thu Sep 30 11:00:47 2021
Job was executed on host(s) <bullet0106>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 11:00:49 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Sep 30 11:00:49 2021
Terminated at Thu Sep 30 11:12:49 2021
Results reported at Thu Sep 30 11:12:49 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2358.3+3830_daily_bin1206 359.588 38.5097 551923201 552182401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2358.3+3830 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   438.40 sec.
    Max Memory :                                 1093 MB
    Average Memory :                             198.62 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   719 sec.
    Turnaround time :                            722 sec.

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

