/sdf/group/fermi/u/kocevski/software/conda/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)

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 make4FGLDR3xml version 01r09.
The default diffuse model files and names are for P8R3, 4FGL DRs, and the default fermitools directory locations.

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

/sdf/group/fermi/u/kocevski/software/conda/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 = 17306
number of fields = 31
RA_SUN column already exists. File will not be modified.
Done.


Performing analysis on: 4FGL_J1838.8+4802_weekly_bin906
RA = 279.714, Dec = 48.0412
tmin = 786931201, tmax = 787536001
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='17380355', job_status='RUN', time_executed='2025-12-16 02:59:56.313259', time_epoch_executed='1765882796.31' WHERE source_name='4FGL J1838.8+4802' and cadence='weekly' and bin_id='906'

Database successfully updated.
Done.

Creating custom output directory:
/lscratch/kocevski/17380355

Creating custom pfile directory:
/lscratch/kocevski/17380355/pfiles/

Retrieving the FT1 file...

Issuing command:
datacat find --group FT1 --filter 'nMetStop>=786931201.0 && nMetStart<787536001.0' /Data/Flight/Reprocess/P305

Issuing command:
datacat find --group FT1 --filter 'nMetStart>564945418 && nMetStop>=786931201.0 && nMetStart<787536001.0' /Data/Flight/Level1/LPA

Retrieving 107 files...
Done.


Merging files...

Checksum keywords updated successfully.

Merged file saved to:
/lscratch/kocevski/17380355/ft1_4FGL_J1838.8+4802_weekly_bin906.fits


Retrieving the FT1 file...

Issuing command:
datacat find --group FT2 --filter 'nMetStop>=786931201.0 && nMetStart<787536001.0' /Data/Flight/Level1/LPA

Retrieving 107 files...
Done.


Merging files...

Merged file saved to:
/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits


Selecting the photons:
time -p gtselect infile=/lscratch/kocevski/17380355/ft1_4FGL_J1838.8+4802_weekly_bin906.fits outfile=/lscratch/kocevski/17380355/ft1_filteredMKT_4FGL_J1838.8+4802_weekly_bin906.fits ra=279.714 dec=48.0412 rad=12.0 tmin=786931201.0 tmax=787536001.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 6.03
user 5.19
sys 0.27

Adding sun position to ft2 file:
/sdf/group/fermi/g/LCRepository/Repository/bin/sunpos /lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits

Selecting the good time intervals:
time -p gtmktime scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits sctable="SC_DATA" filter="IN_SAA!=T && LIVETIME>0 && gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))" roicut=no evfile=/lscratch/kocevski/17380355/ft1_filteredMKT_4FGL_J1838.8+4802_weekly_bin906.fits evtable="EVENTS" outfile="/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.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('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nogrb.gti',(START+STOP)/2) && (angsep(RA_SUN,DEC_SUN,RA_ZENITH,DEC_ZENITH)>115 || gtifilter('/sdf/group/fermi/g/LCRepository/Likelihood/GTIs/nosolarflares.gti',(START+STOP)/2))
real 0.94
user 0.22
sys 0.13

Number of photons that the gtmktime cut: 2546

Generating the livetime cube:
time -p gtltcube evfile="/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits" evtable="EVENTS" scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits sctable="SC_DATA" outfile=/lscratch/kocevski/17380355/ltcube_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.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 /lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits
.....................!
real 19.32
user 18.49
sys 0.24

Generating the exposure map:
time -p gtexpmap evfile=/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits evtable="EVENTS" scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits sctable="SC_DATA" expcube=/lscratch/kocevski/17380355/ltcube_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits outfile=/lscratch/kocevski/17380355/expmap_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.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 /lscratch/kocevski/17380355/ltcube_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits
.....................!
real 71.67
user 66.64
sys 4.01

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 gamma Cygni in ROI with RadialDisk spatial model.
Extended source Cygnus Cocoon in ROI with RadialGaussian spatial model.
Extended source HB 21 in ROI with RadialDisk spatial model.
Added 212 point sources and 3 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 J1838.8+4802 @ 279.714 48.0412

Creating the counts map:
time -p gtbin evfile=/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits outfile=/lscratch/kocevski/17380355/cmap_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.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=279.714 yref=48.0412 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 1.03
user 0.25
sys 0.13

Creating the high resolution counts map:
time -p gtbin evfile=/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits outfile=/lscratch/kocevski/17380355/cmap_HighResolution_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.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=279.714 yref=48.0412 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 1.09
user 0.24
sys 0.12

Computing the diffuse response:
time -p gtdiffrsp evfile=/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits evtable="EVENTS" scfile=/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits sctable="SC_DATA" srcmdl=/lscratch/kocevski/17380355/Model_4FGL_J1838.8+4802_weekly_bin906.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 Cygnus Cocoon
adding source EG_v02
adding source GAL_V02
adding source HB 21
adding source gamma Cygni
Working on...
/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits.....................!
real 95.75
user 93.17
sys 1.08

Creating the likelihood object...
obs = UnbinnedObs('/lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits', '/lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits', expMap='/lscratch/kocevski/17380355/expmap_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits', expCube='/lscratch/kocevski/17380355/ltcube_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits', irfs='P8R3_SOURCE_V2')
like = UnbinnedAnalysis(obs, '/lscratch/kocevski/17380355/Model_4FGL_J1838.8+4802_weekly_bin906.xml', optimizer='MINUIT')

Using source of interest name: '4FGL J1838.8+4802'

4FGL J1838.8+4802
   Spectrum: LogParabola
373         norm:  8.223e+00  0.000e+00  0.000e+00  1.000e+06 ( 1.000e-13)
374        alpha:  1.764e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
375         beta:  4.590e-02  0.000e+00 -5.000e+00  1.000e+01 ( 1.000e+00) fixed
376           Eb:  1.698e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed


Likelihood Fit Parameters:
Event file(s): /lscratch/kocevski/17380355/ft1_filtered_4FGL_J1838.8+4802_weekly_bin906.fits
Spacecraft file(s): /lscratch/kocevski/17380355/ft2_4FGL_J1838.8+4802_weekly_bin906.fits
Exposure map: /lscratch/kocevski/17380355/expmap_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits
Exposure cube: /lscratch/kocevski/17380355/ltcube_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.fits
IRFs: P8R3_SOURCE_V2
Source model file: /lscratch/kocevski/17380355/Model_4FGL_J1838.8+4802_weekly_bin906.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) = 25737.5642597

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

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

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'Prefactor '    3.6068       1.0000          .0000       .10000E+07
     2 'norm      '    4.9081       1.0000          .0000       .10000E+07
     3 'Prefactor '    .26058E-02   1.0000          .0000       .10000E+07
     4 'Prefactor '    24.974       1.0000          .0000       .10000E+07
     5 'Prefactor '    20.609       1.0000          .0000       .10000E+07
     6 'Prefactor '    4.5956       1.0000          .0000       .10000E+07
     7 'norm      '    .35407E-03   1.0000          .0000       .10000E+07
     8 'Prefactor '    .40201E-06   1.0000          .0000       .10000E+07
     9 'norm      '    5.9703       1.0000          .0000       .10000E+07
    10 'norm      '    2.5055       1.0000          .0000       .10000E+07
    11 'norm      '    5.5129       1.0000          .0000       .10000E+07
    12 'Prefactor '    1.4248       1.0000          .0000       .10000E+07
    13 'norm      '    2.5100       1.0000          .0000       .10000E+07
    14 'Normalizat'    1.2593       1.0000         .10000E-01   10.000    
    15 'Prefactor '    .93992       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7340E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 FCN=   25736.91     FROM MIGRAD    STATUS=CONVERGED     85 CALLS      808 TOTAL
                     EDM=   .15E-08  STRATEGY=1  ERROR MATRIX UNCERTAINTY=  2.7%

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  Prefactor     3.6063        2.0813       -.12733E-06   -.18761E-02
   2  norm          4.8892        3.6525       -.17713E-06   -.37186E-02
   3  Prefactor     .57621E-07    392.27        .41661E-04** at limit **
   4  Prefactor     25.020        4.2927        .69320E-06   -.20712E-01
   5  Prefactor     20.594        1.0744        .11262E-06   -.10021    
   6  Prefactor     4.5886        4.7949        .81825E-06   -.14672E-02
   7  norm          .49960E-09    4.6678        .47852E-06** at limit **
   8  Prefactor      .0000        2.1133       -.51797E-06** at limit **
   9  norm          5.9655        3.4750       -.43269E-06   -.99789E-03
  10  norm          2.5050        2.8326       -.40946E-06   -.29474E-02
  11  norm          5.5032        1.4105        .32410E-06   -.19923E-01
  12  Prefactor     1.4244        1.1926        .10287E-06    .39139E-02
  13  norm          2.5098        1.3260       -.53434E-06   -.30127E-01
  14  Normalizat    1.2592        .14868        .11274E-04    .48032E-03
  15  Prefactor     .93994        .68775E-01   -.54381E-05    .20092E-03
                               ERR DEF=  .500    
Final values: 
  Prefactor  = 3.60634
  norm       = 4.88921
  Prefactor  = 5.76206e-08
  Prefactor  = 25.0204
  Prefactor  = 20.5938
  Prefactor  = 4.58856
  norm       = 4.996e-10
  Prefactor  = 0
  norm       = 5.96554
  norm       = 2.50496
  norm       = 5.50317
  Prefactor  = 1.42444
  norm       = 2.50979
  Normalizat = 1.25916
  Prefactor  = 0.939943
 **********
 **   18 **HESSE 
 **********

 FCN=   25736.91     FROM HESSE     STATUS=OK           220 CALLS     1028 TOTAL
                     EDM=   .53E-06    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  Prefactor     3.6063        2.0793        .53179E-03   -1.5670    
   2  norm          4.8892        3.7146        .45377E-03   -1.5664    
   3  Prefactor     .57621E-07    392.24        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   4  Prefactor     25.020        4.5730        .20015E-03   -1.5608    
   5  Prefactor     20.594        21.349        .22035E-03   -1.5617    
   6  Prefactor     4.5886        4.8268        .46930E-03   -1.5665    
   7  norm          .49960E-09    4.6671        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   8  Prefactor      .0000        2.1197        .42118E-03   -1.5708    
                                 WARNING -   - ABOVE PARAMETER IS AT LIMIT.
   9  norm          5.9655        3.4781        .41072E-03   -1.5659    
  10  norm          2.5050        2.8574        .64531E-03   -1.5676    
  11  norm          5.5032        4.6554        .42768E-03   -1.5661    
  12  Prefactor     1.4244        1.2062        .90541E-03   -1.5684    
  13  norm          2.5098        1.3364        .64467E-03   -1.5676    
  14  Normalizat    1.2592        .12578        .78226E-01   -.84794    
  15  Prefactor     .93994        .58167E-01    .45512E-01   -.94759    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 5.34407e-07
Minuit parameter uncertainties:
  1  2.07933
  2  3.71463
  3  0.00951077
  4  4.57303
  5  21.3487
  6  4.82678
  7  9.69074e-05
  8  8.44355e-06
  9  3.47815
  10  2.85742
  11  4.65537
  12  1.20615
  13  1.3364
  14  0.125813
  15  0.0581706
Done.

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

Extracting fit parameters...

4FGL J1838.8+4802
   Spectrum: LogParabola
373         norm:  5.503e+00  4.655e+00  0.000e+00  1.000e+06 ( 1.000e-13)
374        alpha:  1.764e+00  0.000e+00  0.000e+00  5.000e+00 ( 1.000e+00) fixed
375         beta:  4.590e-02  0.000e+00 -5.000e+00  1.000e+01 ( 1.000e+00) fixed
376           Eb:  1.698e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
723    Prefactor:  9.399e-01  5.817e-02  0.000e+00  1.000e+01 ( 1.000e+00)
724        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
725        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
722   Normalization:  1.259e+00  1.258e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Fixed Index): 3.21
Ra Dec: 279.714 48.041
Photon Index (Fixed Index): 1.76 +/- 0.00
Photon Flux (Fixed Index): 8.92e-09 +/- 7.55e-09
Energy Flux (Fixed Index): 1.11e-05 +/- 9.41e-06

TS (Fixed Index): 3.21
Ra Dec: 279.714 48.041
Photon Flux Upper Limit: 2.87461013279e-08 ph cm-2 s-1
Energy Flux Upper Limit: 3.58157378174e-05 MeV cm-2 s-1

Saving results to:
/lscratch/kocevski/17380355/likelihoodResults_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.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) = 25736.3277124
delta logL = 0.581892736649

Fit tolerance = 0.0001

Performing likelihood fit...
Done.

MINUIT Return Code (Free Index): 0
logL (Free Index) = 25736.3092457
delta logL = 0.600359512093

Fit tolerance = 1e-08

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

 PARAMETER DEFINITIONS:
    NO.   NAME         VALUE      STEP SIZE      LIMITS
     1 'norm      '    4.6510       1.0000          .0000       .10000E+07
     2 'alpha     '    1.1449       1.0000          .0000       5.0000    
     3 'Normalizat'    1.2622       1.0000         .10000E-01   10.000    
     4 'Prefactor '    .93991       1.0000          .0000       10.000    
 **********
 **   15 **SET ERR    .5000    
 **********
 **********
 **   16 **SET GRAD    1.000    
 **********
 **********
 **   17 **MINIMIZE    .7340E+05   .2000E-04
 **********

 MIGRAD MINIMIZATION HAS CONVERGED.

 MIGRAD WILL VERIFY CONVERGENCE AND ERROR MATRIX.

 FCN=   25736.31     FROM MIGRAD    STATUS=CONVERGED     56 CALLS      215 TOTAL
                     EDM=   .94E-09    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                   STEP         FIRST   
  NO.   NAME        VALUE          ERROR          SIZE      DERIVATIVE 
   1  norm          4.6501        3.6063        .46643E-03   -.91875E-02
   2  alpha         1.1447        .38001        .50000       -.15962E-03
   3  Normalizat    1.2622        .12183        .78133E-01    .65351E-04
   4  Prefactor     .93991        .57942E-01    .45512E-01   -.42526E-05
                               ERR DEF=  .500    
Final values: 
  norm       = 4.65009
  alpha      = 1.14471
  Normalizat = 1.26223
  Prefactor  = 0.93991
 **********
 **   18 **HESSE 
 **********

 FCN=   25736.31     FROM HESSE     STATUS=OK            33 CALLS      248 TOTAL
                     EDM=   .22E-07    STRATEGY= 1      ERROR MATRIX ACCURATE 

  EXT PARAMETER                                INTERNAL      INTERNAL  
  NO.   NAME        VALUE          ERROR       STEP SIZE       VALUE   
   1  norm          4.6501        4.1799        .93285E-04   -1.5665    
   2  alpha         1.1447        .48555        .28081E-01   -.57295    
   3  Normalizat    1.2622        .14329        .34584E-03   -.84701    
   4  Prefactor     .93991        .68281E-01    .18649E-03   -.94760    
                               ERR DEF=  .500    
Minuit fit quality: 3   estimated distance: 2.24853e-08
Minuit parameter uncertainties:
  1  4.1799
  2  0.489978
  3  0.143336
  4  0.0682871
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) = 25736.3092456
delta logL = 0.600359580629

Extracting fit parameters...

4FGL J1838.8+4802
   Spectrum: LogParabola
373         norm:  4.650e+00  4.180e+00  0.000e+00  1.000e+06 ( 1.000e-13)
374        alpha:  1.145e+00  4.900e-01  0.000e+00  5.000e+00 ( 1.000e+00)
375         beta:  4.590e-02  0.000e+00 -5.000e+00  1.000e+01 ( 1.000e+00) fixed
376           Eb:  1.698e+03  0.000e+00  3.000e+01  5.000e+05 ( 1.000e+00) fixed

GAL_V02
   Spectrum: PowerLaw
723    Prefactor:  9.399e-01  6.829e-02  0.000e+00  1.000e+01 ( 1.000e+00)
724        Index:  0.000e+00  0.000e+00 -1.000e+00  1.000e+00 ( 1.000e+00) fixed
725        Scale:  1.000e+02  0.000e+00  5.000e+01  2.000e+02 ( 1.000e+00) fixed

EG_v02
   Spectrum: FileFunction
722   Normalization:  1.262e+00  1.433e-01  1.000e-02  1.000e+01 ( 1.000e+00)


TS (Free Index): 4.41
Ra Dec: 279.714 48.041
Photon Index (Free Index): 1.14 +/- 0.49
Photon Flux (Free Index): 4.43e-09 +/- 4.04e-09
Energy Flux (Free Index): 3.34e-05 +/- 3.80e-05

Creating a high resolution counts map...
INFO: Auto-setting vmin to -1.000e-01 [aplpy.core]
INFO: Auto-setting vmax to  1.110e+00 [aplpy.core]
Saving /lscratch/kocevski/17380355/cmap_HighResolution_786931201_787536001_4FGL_J1838.8+4802_weekly_bin906.png

Cleaning up...

** Nuclear option initiated! **

Updating database...

UPDATE lightcurve_data_v2 SET energy_flux_upper_limit='3.58e-05', comment='SUCCESS', photon_flux='8.92e-09', energy_flux2='3.34e-05', photon_flux_error='7.55e-09', dlogl='6.00e-01', energy_flux='1.11e-05', photon_flux2='4.43e-09', job_status='DONE', time_completed='2025-12-16 03:13:32.931472', photon_index_error2='0.49', photon_index2='1.14', ts='3.21', fit_tolerance='1e-08', GAL='0.94', photon_index_error='0.00', photon_flux_upper_limit='2.87e-08', energy_flux_error2='3.80e-05', EG='1.26', time_epoch_completed='1765883612.93', return_code='0', job_id='17380355', GAL2='0.94', EG2='1.26', return_code2='0', energy_flux_error='9.41e-06', photon_flux_error2='4.04e-09', ts2='4.41', photon_index='1.76' WHERE bin_id='906' AND source_name='4FGL J1838.8+4802' AND cadence='weekly';

Database successfully updated.


Analysis Complete.


Tue Dec 16 03:13:33 PST 2025

