bdat.steps package#

Submodules#

bdat.steps.find_steps module#

bdat.steps.find_steps.find_linear_steps(data: CyclingData, maxCurrentError=0.05, maxCurrentRMSE=0.002, maxVoltageError=0.005, maxVoltageRMSE=0.00125, maxPowerError=0.01, maxPowerRMSE=0.002) Steplist#
bdat.steps.find_steps.find_steps(data: CyclingData, maxCurrentError=0.05, maxCurrentRMSE=0.002, maxVoltageError=0.005, maxVoltageRMSE=0.00125, maxPowerError=0.01, maxPowerRMSE=0.002) Steplist#
bdat.steps.find_steps.steps_from_columns(data: CyclingData, *columns: str) Steplist#

bdat.steps.step_pattern module#

class bdat.steps.step_pattern.And(a: StepPattern, b: StepPattern)#

Bases: StepPattern

a: StepPattern#
b: StepPattern#
matchStep(step: Step) bool#
match_at_position(steplist: list[Step], position: int) Match | None#
to_str() str#
class bdat.steps.step_pattern.CCProperties(duration: Tuple[float, float] | None = None, current: Tuple[float, float] | None = None, voltageStart: Tuple[float, float] | None = None, voltageEnd: Tuple[float, float] | None = None)#

Bases: StepPattern

current: Tuple[float, float] | None#
duration: Tuple[float, float] | None#
matchStep(step: Step) bool#
to_str() str#
voltageEnd: Tuple[float, float] | None#
voltageStart: Tuple[float, float] | None#
class bdat.steps.step_pattern.CPProperties(duration: Tuple[float, float] | None = None, power: Tuple[float, float] | None = None, voltageStart: Tuple[float, float] | None = None, voltageEnd: Tuple[float, float] | None = None, currentStart: Tuple[float, float] | None = None, currentEnd: Tuple[float, float] | None = None)#

Bases: StepPattern

currentEnd: Tuple[float, float] | None#
currentStart: Tuple[float, float] | None#
duration: Tuple[float, float] | None#
matchStep(step: Step) bool#
power: Tuple[float, float] | None#
to_str() str#
voltageEnd: Tuple[float, float] | None#
voltageStart: Tuple[float, float] | None#
class bdat.steps.step_pattern.CVProperties(duration: Tuple[float, float] | None = None, voltage: Tuple[float, float] | None = None, currentStart: Tuple[float, float] | None = None, currentEnd: Tuple[float, float] | None = None)#

Bases: StepPattern

currentEnd: Tuple[float, float] | None#
currentStart: Tuple[float, float] | None#
duration: Tuple[float, float] | None#
matchStep(step: Step) bool#
to_str() str#
voltage: Tuple[float, float] | None#
class bdat.steps.step_pattern.Not(a: StepPattern)#

Bases: StepPattern

a: StepPattern#
matchStep(step: Step) bool#
to_str() str#
class bdat.steps.step_pattern.Or(a: StepPattern, b: StepPattern)#

Bases: StepPattern

a: StepPattern#
b: StepPattern#
matchStep(step: Step) bool#
match_at_position(steplist: list[Step], position: int) Match | None#
to_str() str#
class bdat.steps.step_pattern.PauseProperties(duration: Tuple[float, float] | None = None, voltageStart: Tuple[float, float] | None = None, voltageEnd: Tuple[float, float] | None = None)#

Bases: StepPattern

duration: Tuple[float, float] | None#
matchStep(step: Step) bool#
to_str() str#
voltageEnd: Tuple[float, float] | None#
voltageStart: Tuple[float, float] | None#
class bdat.steps.step_pattern.StepDuration(min: float, max: float)#

Bases: StepPattern

matchStep(step: Step) bool#
max: float#
min: float#
class bdat.steps.step_pattern.StepPattern#

Bases: SteplistPattern, ABC

abstract matchStep(step: Step) bool#
match_at_position(steplist: list[Step], position: int) Match | None#
class bdat.steps.step_pattern.StepProperties(stepType: type[Step] | None = None, duration: Tuple[float, float] | None = None, current: Tuple[float, float] | None = None, voltage: Tuple[float, float] | None = None)#

Bases: StepPattern

current: Tuple[float, float] | None#
duration: Tuple[float, float] | None#
matchStep(step: Step) bool#
stepType: type[Step] | None#
to_str() str#
voltage: Tuple[float, float] | None#
class bdat.steps.step_pattern.StepType(stepType: type[Step])#

Bases: StepPattern

matchStep(step: Step) bool#
stepType: type[Step]#
to_str() str#
class bdat.steps.step_pattern.StepValue(min: float, max: float)#

Bases: StepPattern

matchStep(step: Step) bool#
max: float#
min: float#

bdat.steps.steplist_pattern module#

class bdat.steps.steplist_pattern.Match(start: int, end: int, length: int, pattern: 'SteplistPattern', steps: List[bdat.entities.steps.step.Step], subMatches: List[ForwardRef('Match')] = <factory>)#

Bases: object

end: int#
get_matches(pattern: SteplistPattern)#
length: int#
pattern: SteplistPattern#
start: int#
steps: List[Step]#
subMatches: List[Match]#
class bdat.steps.steplist_pattern.Optional(pattern: SteplistPattern)#

Bases: Repeat

class bdat.steps.steplist_pattern.Or(*patterns: SteplistPattern)#

Bases: SteplistPattern

match_at_position(steplist: list[Step], position: int) Match | None#
patterns: list[SteplistPattern]#
to_str() str#
class bdat.steps.steplist_pattern.Repeat(pattern: SteplistPattern, min: int | None = None, max: int | None = None)#

Bases: SteplistPattern

match_at_position(steplist: list[Step], position: int) Match | None#
max: int | None#
min: int | None#
pattern: SteplistPattern#
to_str() str#
class bdat.steps.steplist_pattern.RepeatSteps(pattern: SteplistPattern, conditions: List[Tuple[StepPattern, Dict[str, Tuple[float | None, float | None]]]], min: int | None = None, max: int | None = None)#

Bases: SteplistPattern

conditions: List[Tuple[StepPattern, Dict[str, Tuple[float | None, float | None]]]]#
match_at_position(steplist: list[Step], position: int) Match | None#
max: int | None#
min: int | None#
pattern: SteplistPattern#
to_str() str#
class bdat.steps.steplist_pattern.Series(patterns: list[SteplistPattern], duration: Tuple[float, float] | None = None)#

Bases: SteplistPattern

duration: Tuple[float, float] | None = None#
match_at_position(steplist: list[Step], position: int) Match | None#
patterns: list[SteplistPattern]#
to_str() str#
class bdat.steps.steplist_pattern.SteplistPattern#

Bases: ABC

match(steplist: Steplist) Iterator[Match]#
abstract match_at_position(steplist: list[Step], position: int) Match | None#
abstract to_str() str#

Module contents#