/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 128 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_J2359.0+3922_daily_bin1206
RA = 359.755, Dec = 39.3669
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='239078', job_status='RUN', time_executed='2021-09-30 11:53:03.160799', time_epoch_executed='1633027983.16' WHERE source_name='4FGL J2359.0+3922' and cadence='daily' and bin_id='1206'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/239078

Creating custom pfile directory:
/scratch/kocevski/239078/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/239078/ft1_4FGL_J2359.0+3922_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/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/239078/ft1_4FGL_J2359.0+3922_daily_bin1206.fits outfile=/scratch/kocevski/239078/ft1_filteredMKT_4FGL_J2359.0+3922_daily_bin1206.fits ra=359.755 dec=39.3669 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.68
user 3.45
sys 0.21

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_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/239078/ft1_filteredMKT_4FGL_J2359.0+3922_daily_bin1206.fits evtable="EVENTS" outfile="/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_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.48
user 0.33
sys 0.14

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits" evtable="EVENTS" scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits sctable="SC_DATA" outfile=/scratch/kocevski/239078/ltcube_551923201_552182401_4FGL_J2359.0+3922_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/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits
.....................!
real 11.45
user 11.06
sys 0.37

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits evtable="EVENTS" scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits sctable="SC_DATA" expcube=/scratch/kocevski/239078/ltcube_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits outfile=/scratch/kocevski/239078/expmap_551923201_552182401_4FGL_J2359.0+3922_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/239078/ltcube_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits
.....................!
real 190.65
user 185.52
sys 4.82

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.
Extended source CTB 109 in ROI with RadialDisk spatial model.
Added 160 point sources and 2 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 J2359.0+3922 @ 359.755 39.3669

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits outfile=/scratch/kocevski/239078/cmap_551923201_552182401_4FGL_J2359.0+3922_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.755 yref=39.3669 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.37
sys 0.14

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits outfile=/scratch/kocevski/239078/cmap_HighResolution_551923201_552182401_4FGL_J2359.0+3922_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.755 yref=39.3669 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/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits evtable="EVENTS" scfile=/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/239078/Model_4FGL_J2359.0+3922_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 CTB 109
adding source EG_v02
adding source FHES J2304.0+5406
adding source GAL_V02
Working on...
/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits......................!
real 32.66
user 31.39
sys 1.20

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits', '/scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits', expMap='/scratch/kocevski/239078/expmap_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits', expCube='/scratch/kocevski/239078/ltcube_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/239078/Model_4FGL_J2359.0+3922_daily_bin1206.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J2359.0+3922'

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  1.197e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  2.348e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/239078/ft1_filtered_4FGL_J2359.0+3922_daily_bin1206.fits
Spacecraft file(s): /scratch/kocevski/239078/ft2_4FGL_J2359.0+3922_daily_bin1206.fits
Exposure map: /scratch/kocevski/239078/expmap_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits
Exposure cube: /scratch/kocevski/239078/ltcube_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/239078/Model_4FGL_J2359.0+3922_daily_bin1206.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) = 2071.33552985

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .10132E-01   1.0000         .10000E-03   10000.    
     2 'Prefactor '    74.176       1.0000         .10000E-03   10000.    
     3 'norm      '    .11553E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10057E-03   1.0000         .10000E-03   10000.    
     5 'norm      '    73.596       1.0000         .10000E-03   10000.    
     6 'Prefactor '    27.559       1.0000         .10000E-03   10000.    
     7 'Prefactor '    .10044E-03   1.0000         .10000E-03   10000.    
     8 'Prefactor '    76.846       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10027E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '    .10291E-03   1.0000         .10000E-03   10000.    
    11 'norm      '    .10016E-03   1.0000         .10000E-03   10000.    
    12 'Prefactor '    30.998       1.0000         .10000E-03   10000.    
    13 'Prefactor '    43.113       1.0000         .10000E-03   10000.    
    14 'norm      '    6.9835       1.0000         .10000E-03   10000.    
    15 'Prefactor '    31.822       1.0000         .10000E-03   10000.    
    16 'norm      '    16.739       1.0000         .10000E-03   10000.    
    17 'norm      '    .10001E-03   1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10216E-03   1.0000         .10000E-03   10000.    
    19 'norm      '    .10025E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    .10096E-03   1.0000         .10000E-03   10000.    
    21 'Prefactor '    729.48       1.0000         .10000E-03   10000.    
    22 'Prefactor '    202.84       1.0000         .10000E-03   10000.    
    23 'Prefactor '    197.25       1.0000         .10000E-03   10000.    
    24 'Prefactor '    .24248E-03   1.0000         .10000E-03   10000.    
    25 'Normalizat'    .37114       1.0000         .10000E-01   10.000    
    26 'Prefactor '    .96125       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5320E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2071.266     FROM MIGRAD    STATUS=CONVERGED    585 CALLS     4071 TOTAL
                     EDM=   .47E-09  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.1%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10005E-03    1546.5       -.60485E-04** at limit **
   2  Prefactor     73.542        486.00       -.38160E-04    .18622E-04
   3  norm          .10000E-03    49.661        .26876E-05** at limit **
   4  Prefactor     .10000E-03    10.438        .39253E-06** at limit **
   5  norm          73.613        97.918        .31561E-06    .18991E-04
   6  Prefactor     27.586        17.834       -.21344E-05   -.33665E-03
   7  Prefactor     .10000E-03    14.094        .27744E-06** at limit **
   8  Prefactor     77.029        222.71       -.15921E-05    .69396E-05
   9  Prefactor     .10000E-03    34.194       -.43939E-06** at limit **
  10  Prefactor     .10000E-03    107.71        .61723E-06** at limit **
  11  norm          .10000E-03    1.8098       -.66204E-06** at limit **
  12  Prefactor     31.009        19.524       -.91028E-06   -.11318E-03
  13  Prefactor     43.087        122.79        .19005E-05   -.36283E-04
  14  norm          6.9859        5.2075       -.69580E-06   -.39050E-03
  15  Prefactor     31.891        81.870       -.39041E-05   -.59768E-04
  16  norm          16.741        11.864       -.23100E-06   -.21454E-03
  17  norm          .10000E-03    30.990        .49638E-06** at limit **
  18  Prefactor     .10000E-03    63.600       -.60117E-06** at limit **
  19  norm          .10000E-03    20.119        .41184E-05** at limit **
  20  Prefactor     .10000E-03    22.163        .17980E-06** at limit **
  21  Prefactor     729.94        832.15        .24186E-05    .11577E-04
  22  Prefactor     202.90        108.42       -.69012E-05   -.12226E-03
  23  Prefactor     197.46        200.47       -.64158E-05   -.52814E-04
  24  Prefactor     .10001E-03    64.573        .12196E-04** at limit **
  25  Normalizat    .36988        .53879        .57666E-04   -.12948E-05
  26  Prefactor     .96172        .25726       -.13673E-04   -.15645E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100052
  Prefactor  = 73.5416
  norm       = 0.000100002
  Prefactor  = 0.0001
  norm       = 73.6127
  Prefactor  = 27.5856
  Prefactor  = 0.0001
  Prefactor  = 77.0286
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  norm       = 0.0001
  Prefactor  = 31.0085
  Prefactor  = 43.087
  norm       = 6.98595
  Prefactor  = 31.8914
  norm       = 16.7408
  norm       = 0.0001
  Prefactor  = 0.0001
  norm       = 0.000100001
  Prefactor  = 0.0001
  Prefactor  = 729.936
  Prefactor  = 202.899
  Prefactor  = 197.462
  Prefactor  = 0.000100012
  Normalizat = 0.369882
  Prefactor  = 0.961715
 **********
 **   18 **HESSE 
 **********

 FCN=   2071.266     FROM HESSE     STATUS=OK           438 CALLS     4509 TOTAL
                     EDM=   .88E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10005E-03    1530.1        .18147E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Prefactor     73.542        481.02        .23309E-03   -1.3991    
   3  norm          .10000E-03    49.663        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    10.440        .14360E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  norm          73.613        97.921        .23400E-03   -1.3990    
   6  Prefactor     27.586        17.888        .76314E-04   -1.4657    
   7  Prefactor     .10000E-03    14.101        .16679E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor     77.029        222.26        .22904E-03   -1.3950    
   9  Prefactor     .10000E-03    34.210        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor     .10000E-03    107.76        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  norm          .10000E-03    1.8268        .59843E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  Prefactor     31.009        19.544        .71965E-04   -1.4594    
  13  Prefactor     43.087        122.90        .61055E-04   -1.4394    
  14  norm          6.9859        5.2001        .81324E-04   -1.5179    
  15  Prefactor     31.891        81.832        .71030E-04   -1.4578    
  16  norm          16.741        11.880        .48947E-03   -1.4889    
  17  norm          .10000E-03    30.997        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  18  Prefactor     .10000E-03    63.862        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  norm          .10000E-03    20.239        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     .10000E-03    22.175        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  21  Prefactor     729.94        833.41        .76908E-04   -1.0237    
  22  Prefactor     202.90        108.12        .14187E-03   -1.2849    
  23  Prefactor     197.46        202.29        .14383E-03   -1.2888    
  24  Prefactor     .10001E-03    64.021        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Normalizat    .36988        .53758        .57771E-03   -1.1889    
  26  Prefactor     .96172        .26436        .18660E-03   -.94017    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 8.79679e-10
Minuit parameter uncertainties:
  1  0.0183646
  2  380.708
  3  0.00066676
  4  2.99705e-05
  5  98.1366
  6  17.8915
  7  3.70452e-06
  8  224.727
  9  4.58873e-06
  10  0.000227044
  11  4.55634e-06
  12  19.5484
  13  123.633
  14  5.20039
  15  82.1223
  16  11.882
  17  2.05114e-05
  18  0.000113055
  19  0.000321012
  20  7.1301e-05
  21  848.372
  22  108.229
  23  203.009
  24  0.0017738
  25  0.545347
  26  0.264711
Done.

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

Extracting fit parameters...

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  1.000e-04  1.774e-03  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  2.348e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
529    Prefactor:  9.617e-01  2.647e-01  0.000e+00  1.000e+01 ( 1.000e+00)
530        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
531        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
524   Normalization:  3.699e-01  5.453e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 359.755 39.367
Photon Flux Upper Limit: 3.84e-07 ph cm-2 s-1
Energy Flux Upper Limit: 2.96e-02 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/239078/likelihoodResults_551923201_552182401_4FGL_J2359.0+3922_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): 102
logL (Free Index) = 2071.26599527
delta logL = -7.43595123822e-05

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 2071.26416221
delta logL = 0.00175869956956

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    .57945       1.0000         .10000E-03   10000.    
     2 'Index     '    3.0896       1.0000          .0000       10.000    
     3 'Normalizat'    .36601       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .96003       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5320E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   2071.264     FROM MIGRAD    STATUS=CONVERGED     70 CALLS      299 TOTAL
                     EDM=   .33E-09    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE        STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .59884        13.869        .78916E-01    .23935E-03
   2  Index         3.0809        .50968        .50000       -.21399E-05
   3  Normalizat    .36493        .15309E-01    .13123        .81667E-04
   4  Prefactor     .96159        .78317E-02    .45766E-01    .91359E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.598836
  Index      = 3.08092
  Normalizat = 0.36493
  Prefactor  = 0.961592
 **********
 **   18 **HESSE 
 **********

 FCN=   2071.264     FROM HESSE     STATUS=OK            33 CALLS      332 TOTAL
                     EDM=   .78E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .59884        83.542        .23430E-02   -1.5553    
   2  Index         3.0809        6.5404        .34787E-02   -.39393    
   3  Normalizat    .36493        .49895        .58141E-03   -1.1915    
   4  Prefactor     .96159        .25481        .18656E-03   -.94021    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 7.77126e-10
Minuit parameter uncertainties:
  1  14.1651
  2  5.44561
  3  0.50521
  4  0.255131
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/239078': 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) = 2071.26411689
delta logL = 0.00180401463012

Extracting fit parameters...

4FGL J2359.0+3922
   Spectrum: PowerLaw
518    Prefactor:  5.988e-01  1.417e+01  1.000e-04  1.000e+04 ( 1.000e-13)
519        Index:  3.081e+00  5.446e+00  0.000e+00  1.000e+01 (-1.000e+00)
520        Scale:  1.622e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
529    Prefactor:  9.616e-01  2.551e-01  0.000e+00  1.000e+01 ( 1.000e+00)
530        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
531        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
524   Normalization:  3.649e-01  5.052e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 359.755 39.367

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/239078/cmap_HighResolution_551923201_552182401_4FGL_J2359.0+3922_daily_bin1206.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='2.96e-02', job_status='DONE', photon_flux_upper_limit='3.84e-07', time_completed='2021-09-30 12:02:08.376040', job_id='239078', GAL2='0.96', fit_tolerance='1e-08', EG2='0.36', EG='0.37', time_epoch_completed='1633028528.38', return_code2='0', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.96', dlogl='1.80e-03', ts2='0.00', photon_index_error='0.00', photon_index='2.35' WHERE bin_id='1206' AND source_name='4FGL J2359.0+3922' AND cadence='daily';

Database successfully updated.


Analysis Complete.


Thu Sep 30 12:02:08 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0125>
Subject: Job 239078: <4FGL_J2359.0+3922_daily_bin1206> in cluster <slac> Done

Job <4FGL_J2359.0+3922_daily_bin1206> was submitted from host <rhel6-64p> by user <kocevski> in cluster <slac> at Thu Sep 30 11:50:45 2021
Job was executed on host(s) <bullet0125>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Sep 30 11:50:47 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:50:47 2021
Terminated at Thu Sep 30 12:02:08 2021
Results reported at Thu Sep 30 12:02:08 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J2359.0+3922_daily_bin1206 359.755 39.3669 551923201 552182401 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J2359.0+3922 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   454.00 sec.
    Max Memory :                                 1256 MB
    Average Memory :                             270.55 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   681 sec.
    Turnaround time :                            683 sec.

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

