opensbt.utils package
Submodules
opensbt.utils.duplicates module
opensbt.utils.encoder_utils module
- class opensbt.utils.encoder_utils.NumpyEncoder(*, skipkeys=False, ensure_ascii=True, check_circular=True, allow_nan=True, sort_keys=False, indent=None, separators=None, default=None)[source]
Bases:
JSONEncoder
- default(obj)[source]
Implement this method in a subclass such that it returns a serializable object for
o
, or calls the base implementation (to raise aTypeError
).For example, to support arbitrary iterators, you could implement default like this:
def default(self, o): try: iterable = iter(o) except TypeError: pass else: return list(iterable) # Let the base class default method raise the TypeError return JSONEncoder.default(self, o)
opensbt.utils.evaluation module
opensbt.utils.fps module
opensbt.utils.geometric module
opensbt.utils.log_utils module
opensbt.utils.path module
opensbt.utils.result_utils module
opensbt.utils.sampling module
- opensbt.utils.sampling.cartesian_by_bounds(n_var, xl, xu, n_samples_one_axis)[source]
Generates aequidistant points in a grid shape.
- Input:
n_var: number of axis x_l: lower bound for each axis x_u: upper_bound for each axis n_samples_one_axis: number of samples for one axis
Output: aequidistant points in a grid shape where space is defined by axis with lower/upper bounds xl/xu ((TODO Pass number of samples for each axis via algorithm definition))