You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When attempting to use a pathlib.Path object in python, via a GtApp call or something like creating a BinnedObs object, the fermitools throw an error (see below). This isn't a major issue as converting the Path objects to strings still works.
When attempting to use a pathlib.Path object in python, via a GtApp call or something like creating a BinnedObs object, the fermitools throw an error (see below). This isn't a major issue as converting the Path objects to strings still works.
Simple example reproducing the error:
In [1]: from BinnedAnalysis import *
In [2]: from pathlib import Path
In [3]: sm=Path('sm_TCrB.fits')
In [4]: ltc=Path('ltc_TCrB.fits')
In [5]: bdem=Path('bdem_TCrB.fits')
In [6]: obs=BinnedObs(sm,ltc,bdem)
TypeError Traceback (most recent call last)
Cell In[6], line 1
----> 1 obs=BinnedObs(sm,ltc,bdem)
File /Software/miniconda3/envs/fermi/lib/python3.9/site-packages/fermitools/BinnedAnalysis.py:63, in BinnedObs.init(self, srcMaps, expCube, binnedExpMap, irfs, phased_expmap)
61 self.phased_expmap = phased_expmap
62 if irfs is None or irfs == 'CALDB':
---> 63 my_cuts = pyLike.Cuts(srcMaps, "", False, True, True)
64 self.irfs = my_cuts.CALDB_implied_irfs()
65 else:
File /Software/miniconda3/envs/fermi/lib/python3.9/site-packages/fermitools/pyLikelihood.py:1950, in Cuts.init(self, *args)
1943 def init(self, *args):
1944 r"""
1945 init(Cuts self) -> Cuts
1946 init(Cuts self, std::string const & eventFile, std::string const & extension, bool check_columns=True, bool skipTimeRangeCuts=False, bool skipEventClassCuts=False) -> Cuts
1947 init(Cuts self, StringVector eventFiles, std::string const & extension, bool check_columns=True, bool skipTimeRangeCuts=False, bool skipEventClassCuts=False) -> Cuts
1948 init(Cuts self, Cuts rhs) -> Cuts
1949 """
-> 1950 _pyLikelihood.Cuts_swiginit(self, _pyLikelihood.new_Cuts(*args))
TypeError: Wrong number or type of arguments for overloaded function 'new_Cuts'.
Possible C/C++ prototypes are:
dataSubselector::Cuts::Cuts()
dataSubselector::Cuts::Cuts(std::string const &,std::string const &,bool,bool,bool)
dataSubselector::Cuts::Cuts(std::string const &,std::string const &,bool,bool)
dataSubselector::Cuts::Cuts(std::string const &,std::string const &,bool)
dataSubselector::Cuts::Cuts(std::string const &,std::string const &)
dataSubselector::Cuts::Cuts(std::vector< std::string,std::allocator< std::string > > const &,std::string const &,bool,bool,bool)
dataSubselector::Cuts::Cuts(std::vector< std::string,std::allocator< std::string > > const &,std::string const &,bool,bool)
dataSubselector::Cuts::Cuts(std::vector< std::string,std::allocator< std::string > > const &,std::string const &,bool)
dataSubselector::Cuts::Cuts(std::vector< std::string,std::allocator< std::string > > const &,std::string const &)
dataSubselector::Cuts::Cuts(dataSubselector::Cuts const &)
The text was updated successfully, but these errors were encountered: