Skip to content

Commit

Permalink
fix?
Browse files Browse the repository at this point in the history
  • Loading branch information
VanyaBelyaev committed Jul 24, 2024
1 parent 2437cb3 commit 9a3f033
Show file tree
Hide file tree
Showing 9 changed files with 325 additions and 350 deletions.
13 changes: 9 additions & 4 deletions ostap/core/ostap_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@
'sequence_types' , ## sequence types
'iterable_types' , ## iterable
'sized_types' , ## sized types
'path_types' , ## path-like types
'path_types' , ## path-like types
'ordered_dict' , ## normal/ordered dict
##
'is_integer' , ## is a value of int-like type?
'is_number' , ## is a value of numeric type?
Expand Down Expand Up @@ -76,11 +77,9 @@
# =============================================================================
logger.debug ( 'Core objects/classes/functions for Ostap')
# =============================================================================

iterable_types = Iterable,
num_types = integer_types + ( float , )
str_types = str,

list_types = list , tuple
import array
listlike_types = list_types + ( set , C.Sequence , array.array )
Expand All @@ -99,7 +98,13 @@
if (3,6) <= python_version :
path_types = string_types + ( os.PathLike , )
# =============================================================================

## sometimewe we need to ensure that dictionary is ordered
ordered_dict = dict
if python_version < ( 3 , 7 ) :
from collections import OrderedDict as ordered_dict
dictlike_types += ( ordered_dict, )
dict_types += ( ordered_dict, )

# =============================================================================
## Is this number of a proper integer?
def is_integer ( v ) :
Expand Down
5 changes: 0 additions & 5 deletions ostap/fitting/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -763,10 +763,6 @@ def _rds_make_unique_ ( dataset ,
ROOT.RooAbsData . sample = _rad_sample_
ROOT.RooAbsData . shuffle = _rad_shuffle_

from ostap.trees.trees import _stat_covs_

ROOT.RooAbsData . statCovs = _stat_covs_

from ostap.stats.statvars import data_the_moment
ROOT.RooAbsData. the_moment = data_the_moment

Expand Down Expand Up @@ -802,7 +798,6 @@ def _rds_make_unique_ ( dataset ,
ROOT.RooAbsData . sample ,
ROOT.RooAbsData . shuffle ,
#
ROOT.RooAbsData . statCovs ,
]


Expand Down
Loading

0 comments on commit 9a3f033

Please sign in to comment.