aklog: Couldn't determine realm of user:aklog: unknown RPC error (-1765328189)  while getting realm
/nfs/farm/g/glast/g/LCRepository/bin/miniconda2/envs/fermitools_v1.0.5/lib/python2.7/site-packages/matplotlib/font_manager.py:281: UserWarning: Matplotlib is building the font cache using fc-list. This may take a moment.
  'Matplotlib is building the font cache using fc-list. '
/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 69 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 = 17281
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J0521.2+1637_weekly_bin671
RA = 80.3136, Dec = 16.631
tmin = 644803201, tmax = 645408001
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='954087', job_status='RUN', time_executed='2021-07-08 06:28:43.674206', time_epoch_executed='1625750923.67' WHERE source_name='4FGL J0521.2+1637' and cadence='weekly' and bin_id='671'

Database successfully updated.
Done.

Creating custom output directory:
/scratch/kocevski/954087

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

Retrieving the FT1 file...

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

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

Retrieving 107 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/scratch/kocevski/954087/ft1_4FGL_J0521.2+1637_weekly_bin671.fits


Retrieving the FT1 file...

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

Retrieving 107 files...
Done.


Merging files...

Merged file saved to:
/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits


Selecting the photons:
time -p gtselect infile=/scratch/kocevski/954087/ft1_4FGL_J0521.2+1637_weekly_bin671.fits outfile=/scratch/kocevski/954087/ft1_filteredMKT_4FGL_J0521.2+1637_weekly_bin671.fits ra=80.3136 dec=16.631 rad=12.0 tmin=644803201.0 tmax=645408001.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 8.96
user 5.75
sys 0.28

Adding sun position to ft2 file:
/nfs/farm/g/glast/g/LCRepository/Repository/bin/sunpos /scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits

Selecting the good time intervals:
time -p gtmktime scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.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/954087/ft1_filteredMKT_4FGL_J0521.2+1637_weekly_bin671.fits evtable="EVENTS" outfile="/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.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 1.16
user 0.39
sys 0.17

Generating the livetime cube:
time -p gtltcube evfile="/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits" evtable="EVENTS" scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits sctable="SC_DATA" outfile=/scratch/kocevski/954087/ltcube_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.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/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits
.....................!
real 29.00
user 27.70
sys 0.33

Generating the exposure map:
time -p gtexpmap evfile=/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits evtable="EVENTS" scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits sctable="SC_DATA" expcube=/scratch/kocevski/954087/ltcube_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits outfile=/scratch/kocevski/954087/expmap_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.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/954087/ltcube_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits
.....................!
real 195.95
user 185.43
sys 4.27

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 S 147 in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/S147.fits is the correct path to the extended template.
Extended source IC 443 in ROI with RadialGaussian spatial model.
Extended source Rosette in ROI, make sure /nfs/farm/g/glast/g/LCRepository/Likelihood/ExtendedSources/Extended_archive_v18/Templates/Rosette.fits is the correct path to the extended template.
Extended source Monoceros in ROI with RadialGaussian spatial model.
Added 169 point sources and 4 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 J0521.2+1637 @ 80.3136 16.631

Creating the counts map:
time -p gtbin evfile=/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits outfile=/scratch/kocevski/954087/cmap_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.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=80.3136 yref=16.631 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.86
user 0.41
sys 0.15

Creating the high resolution counts map:
time -p gtbin evfile=/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits outfile=/scratch/kocevski/954087/cmap_HighResolution_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.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=80.3136 yref=16.631 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.69
user 0.44
sys 0.16

Computing the diffuse response:
time -p gtdiffrsp evfile=/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits evtable="EVENTS" scfile=/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits sctable="SC_DATA" srcmdl=/scratch/kocevski/954087/Model_4FGL_J0521.2+1637_weekly_bin671.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
adding source IC 443
adding source Monoceros
adding source Rosette
adding source S 147
Working on...
/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits.....................!
real 69.62
user 63.99
sys 1.25

Creating the likelihood object...
obs = UnbinnedObs('/scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits', '/scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits', expMap='/scratch/kocevski/954087/expmap_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits', expCube='/scratch/kocevski/954087/ltcube_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/scratch/kocevski/954087/Model_4FGL_J0521.2+1637_weekly_bin671.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J0521.2+1637'

4FGL J0521.2+1637
   Spectrum: PowerLaw
242    Prefactor:  4.819e+00  0.000e+00  1.000e-04  1.000e+04 ( 1.000e-14)
243        Index:  2.231e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
244        Scale:  2.276e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /scratch/kocevski/954087/ft1_filtered_4FGL_J0521.2+1637_weekly_bin671.fits
Spacecraft file(s): /scratch/kocevski/954087/ft2_4FGL_J0521.2+1637_weekly_bin671.fits
Exposure map: /scratch/kocevski/954087/expmap_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits
Exposure cube: /scratch/kocevski/954087/ltcube_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.fits
IRFs: P8R3_SOURCE_V2
Source model file: /scratch/kocevski/954087/Model_4FGL_J0521.2+1637_weekly_bin671.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) = 2236.65647636

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    .10021E-03   1.0000         .10000E-03   10000.    
     2 'norm      '    .10111E-03   1.0000         .10000E-03   10000.    
     3 'Prefactor '    .10187E-03   1.0000         .10000E-03   10000.    
     4 'Prefactor '    .10217E-03   1.0000         .10000E-03   10000.    
     5 'Prefactor '    .10006E-03   1.0000         .10000E-03   10000.    
     6 'norm      '    30.629       1.0000         .10000E-03   10000.    
     7 'Prefactor '    60.037       1.0000         .10000E-03   10000.    
     8 'norm      '   10000.0       1.0000         .10000E-03   10000.    
     9 'Prefactor '    .10014E-03   1.0000         .10000E-03   10000.    
    10 'Prefactor '   10000.0       1.0000         .10000E-03   10000.    
    11 'Prefactor '    .10000E-03   1.0000         .10000E-03   10000.    
    12 'norm      '    2804.2       1.0000         .10000E-03   10000.    
    13 'Prefactor '    .18659E-03   1.0000         .10000E-03   10000.    
    14 'norm      '    .10018E-03   1.0000         .10000E-03   10000.    
    15 'norm      '    7.4206       1.0000         .10000E-03   10000.    
    16 'Prefactor '    .10163E-03   1.0000         .10000E-03   10000.    
    17 'norm      '    22.030       1.0000         .10000E-03   10000.    
    18 'Prefactor '    .10159E-03   1.0000         .10000E-03   10000.    
    19 'Prefactor '    .10060E-03   1.0000         .10000E-03   10000.    
    20 'Prefactor '    38.012       1.0000         .10000E-03   10000.    
    21 'Prefactor '    146.81       1.0000         .10000E-03   10000.    
    22 'Prefactor '    .10222E-03   1.0000         .10000E-03   10000.    
    23 'Prefactor '    .10069E-03   1.0000         .10000E-03   10000.    
    24 'Normalizat'    .10000E-01   1.0000         .10000E-01   10.000    
    25 'Prefactor '    .77812       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .5910E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2236.596     FROM MIGRAD    STATUS=CONVERGED    574 CALLS     3448 TOTAL
                     EDM=   .10E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=   .3%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          .10000E-03    20.106        .26090E-06** at limit **
   2  norm          .10000E-03    700.77       -.69931E-06** at limit **
   3  Prefactor     .10000E-03    184.89       -.50580E-06** at limit **
   4  Prefactor     .10000E-03    150.88       -.10784E-05** at limit **
   5  Prefactor     .10000E-03    245.39        .11062E-05** at limit **
   6  norm          30.627        24.182       -.29974E-06    .45062E-04
   7  Prefactor     60.031        65.001       -.38958E-06    .17170E-04
   8  norm         10000.0        1047.2        .19201E-05** at limit **
   9  Prefactor     .10000E-03    239.38        .67607E-06** at limit **
  10  Prefactor    10000.0        2180.6        .31229E-05** at limit **
  11  Prefactor     .10025E-03    2200.6       -.11240E-04** at limit **
  12  norm          2802.4        1003.4        .59966E-05    .63416E-04
  13  Prefactor     .10000E-03    686.98       -.53430E-05** at limit **
  14  norm          .10000E-03    31.266       -.78336E-07** at limit **
  15  norm          7.4201        6.1139       -.31239E-07    .70935E-04
  16  Prefactor     .10000E-03    .30337       -.20486E-05** at limit **
  17  norm          21.967        15.174        .28157E-05    .11500E-02
  18  Prefactor     .10000E-03    3.4745       -.26757E-05** at limit **
  19  Prefactor     .10000E-03    115.24        .16808E-07** at limit **
  20  Prefactor     37.985        148.97       -.95355E-06    .46351E-05
  21  Prefactor     146.87        171.49       -.48220E-06    .30324E-04
  22  Prefactor     .10000E-03    18.437        .69591E-07** at limit **
  23  Prefactor     .10000E-03    39.566       -.24289E-05** at limit **
  24  Normalizat    .10000E-01    .11944       -.62511E-05** at limit **
  25  Prefactor     .77810        .82382E-01    .89036E-06    .33130E-03
                               ERR DEF=  .500    
Final values: 
  norm       = 0.0001
  norm       = 0.000100001
  Prefactor  = 0.000100001
  Prefactor  = 0.000100003
  Prefactor  = 0.000100003
  norm       = 30.6272
  Prefactor  = 60.0307
  norm       = 10000
  Prefactor  = 0.000100003
  Prefactor  = 10000
  Prefactor  = 0.000100253
  norm       = 2802.41
  Prefactor  = 0.0001
  norm       = 0.0001
  norm       = 7.4201
  Prefactor  = 0.0001
  norm       = 21.9666
  Prefactor  = 0.0001
  Prefactor  = 0.000100001
  Prefactor  = 37.9848
  Prefactor  = 146.868
  Prefactor  = 0.0001
  Prefactor  = 0.0001
  Normalizat = 0.01
  Prefactor  = 0.778098
 **********
 **   18 **HESSE 
 **********

 FCN=   2236.596     FROM HESSE     STATUS=OK           407 CALLS     3855 TOTAL
                     EDM=   .24E-08    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          .10000E-03    20.205        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  norm          .10000E-03    700.77        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   3  Prefactor     .10000E-03    184.93        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .10000E-03    150.90        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   5  Prefactor     .10000E-03    245.38        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   6  norm          30.627        24.171        .72397E-04   -1.4601    
   7  Prefactor     60.031        64.987        .51782E-04   -1.4157    
   8  norm         10000.0        1047.0        .20664E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  Prefactor     .10000E-03    239.40        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  10  Prefactor    10000.0        2180.2        .21288E-02    1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  11  Prefactor     .10025E-03    2200.4        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  12  norm          2802.4        1009.9        .44523E-04   -.45506    
  13  Prefactor     .10000E-03    687.62        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  14  norm          .10000E-03    31.273        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  15  norm          7.4201        6.1098        .98951E-04   -1.5163    
  16  Prefactor     .10000E-03    .32026        .48667E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  17  norm          21.967        15.977        .85339E-04   -1.4770    
  18  Prefactor     .10000E-03    3.4539        .85625E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  19  Prefactor     .10000E-03    115.26        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  20  Prefactor     37.985        149.12        .65008E-04   -1.4475    
  21  Prefactor     146.87        171.55        .16629E-03   -1.3278    
  22  Prefactor     .10000E-03    18.476        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  23  Prefactor     .10000E-03    40.290        .18142E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  24  Normalizat    .10000E-01    .12013        .50289E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
  25  Prefactor     .77810        .82662E-01    .13082E-03   -1.0054    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.37936e-09
Minuit parameter uncertainties:
  1  1.97345e-05
  2  0.00173281
  3  0.00079529
  4  0.00134438
  5  0.00179186
  6  24.1783
  7  65.0642
  8  0.00173007
  9  0.00157527
  10  0.00575266
  11  0.04914
  12  1018.64
  13  4.87258e-05
  14  1.00507e-06
  15  6.11033
  16  1.48173e-05
  17  15.9805
  18  5.1153e-05
  19  0.000601395
  20  150.621
  21  172.142
  22  1.33927e-05
  23  0.000111087
  24  7.95709e-08
  25  0.082675
Done.

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

Extracting fit parameters...

4FGL J0521.2+1637
   Spectrum: PowerLaw
242    Prefactor:  1.003e-04  4.914e-02  1.000e-04  1.000e+04 ( 1.000e-14)
243        Index:  2.231e+00  0.000e+00  0.000e+00  1.000e+01 (-1.000e+00) fixed
244        Scale:  2.276e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
572    Prefactor:  7.781e-01  8.267e-02  0.000e+00  1.000e+01 ( 1.000e+00)
573        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
574        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
571   Normalization:  1.000e-02  7.957e-08  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): -0.00
Ra Dec: 80.314 16.631
Photon Flux Upper Limit: 7.30e-06 ph cm-2 s-1
Energy Flux Upper Limit: 5.57e-01 MeV cm-2 s-1

Saving results to:
/scratch/kocevski/954087/likelihoodResults_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.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) = 2236.59638919
delta logL = -3.99161945097e-06

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 102
logL (Free Index) = 2236.5963872
delta logL = -1.99981104743e-06

Fit tolerance = 1e-08

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

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

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   2236.596     FROM MIGRAD    STATUS=CONVERGED     49 CALLS      192 TOTAL
                     EDM=   .39E-11  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  6.5%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     .10003E-03    2198.6       -.19492E-02** at limit **
   2  Index         2.2280        6.1090       -.62105E-03    .63156E-07
   3  Normalizat    .10000E-01    .11400       -.40055E-07** at limit **
   4  Prefactor     .77810        .76283E-01    .27398E-07    .30810E-04
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 0.000100031
  Index      = 2.22799
  Normalizat = 0.01
  Prefactor  = 0.778097
 **********
 **   18 **HESSE 
 **********

 FCN=   2236.596     FROM HESSE     STATUS=NOT POSDEF    29 CALLS      221 TOTAL
                     EDM=   .53E-06    STRATEGY= 1      ERR MATRIX NOT POS-DEF

  EXT PARAMETER                APPROXIMATE     INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     .10003E-03    6449.4        .18143E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   2  Index         2.2280        5.3515        .20000       -.58764    
   3  Normalizat    .10000E-01    .15678E-01    .50290E-02   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     .77810        .27359E-01    .13082E-03   -1.0054    
                               ERR DEF=  .500    
Minuit fit quality: 2   estimated distance: 5.26949e-07
Minuit parameter uncertainties:
  1  0.130223
  2  49625.6
  3  3.63743e-09
  4  0.0273595
shell-init: error retrieving current directory: getcwd: cannot access parent directories: No such file or directory
rmdir: failed to remove `/scratch/kocevski/954087': 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) = 2236.5963852
delta logL = 1.29602995003e-10

Extracting fit parameters...

4FGL J0521.2+1637
   Spectrum: PowerLaw
242    Prefactor:  1.000e-04  1.302e-01  1.000e-04  1.000e+04 ( 1.000e-14)
243        Index:  2.228e+00  4.963e+04  0.000e+00  1.000e+01 (-1.000e+00)
244        Scale:  2.276e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
572    Prefactor:  7.781e-01  2.736e-02  0.000e+00  1.000e+01 ( 1.000e+00)
573        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
574        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
571   Normalization:  1.000e-02  3.637e-09  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): -0.00
Ra Dec: 80.314 16.631

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/954087/cmap_HighResolution_644803201_645408001_4FGL_J0521.2+1637_weekly_bin671.png

Cleaning up...

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

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='5.57e-01', job_status='DONE', photon_flux_upper_limit='7.30e-06', time_completed='2021-07-08 06:38:13.321476', job_id='954087', GAL2='0.78', fit_tolerance='1e-08', EG2='0.01', EG='0.01', time_epoch_completed='1625751493.32', return_code2='102', ts='-0.00', comment='SUCCESS', return_code='0', GAL='0.78', dlogl='1.30e-10', ts2='-0.00', photon_index_error='0.00', photon_index='2.23' WHERE bin_id='671' AND source_name='4FGL J0521.2+1637' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Thu Jul  8 06:38:13 PDT 2021


------------------------------------------------------------
Sender: LSF System <lsf@bullet0176>
Subject: Job 954087: <4FGL_J0521.2+1637_weekly_bin671> in cluster <slac> Done

Job <4FGL_J0521.2+1637_weekly_bin671> was submitted from host <rhel6-64n> by user <kocevski> in cluster <slac> at Thu Jul  8 06:23:41 2021
Job was executed on host(s) <bullet0176>, in queue <medium>, as user <kocevski> in cluster <slac> at Thu Jul  8 06:25:50 2021
</u/ki/kocevski> was used as the home directory.
</u/ki/kocevski> was used as the working directory.
Started at Thu Jul  8 06:25:50 2021
Terminated at Thu Jul  8 06:38:17 2021
Results reported at Thu Jul  8 06:38:17 2021

Your job looked like:

------------------------------------------------------------
# LSBATCH: User input
/nfs/farm/g/glast/g/LCRepository/Likelihood/Scripts/LikelihoodAnalysis.py 4FGL_J0521.2+1637_weekly_bin671 80.3136 16.631 644803201 645408001 irfs=P8R3_SOURCE_V2 zmax=90 ROI=12 association=4FGL_J0521.2+1637 fixedModel=True performFreeIndexFit=True freeVariableSources=True nuke=True repositoryJob=True verbose=False
------------------------------------------------------------

Successfully completed.

Resource usage summary:

    CPU time :                                   538.02 sec.
    Max Memory :                                 1257 MB
    Average Memory :                             263.42 MB
    Total Requested Memory :                     -
    Delta Memory :                               -
    Max Swap :                                   -
    Max Processes :                              5
    Max Threads :                                21
    Run time :                                   746 sec.
    Turnaround time :                            876 sec.

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

