def __init__(self) -> None: self._athlete: typing.Optional[str] = None self._title: typing.Optional[str] = None self.tracks_by_date: typing.Dict[ str, typing.List[Track]] = defaultdict(list) self.tracks: typing.List[Track] = [] self.length_range = QuantityRange() self.length_range_by_date = QuantityRange() self.total_length_year_dict: typing.Dict[ int, pint.quantity.Quantity] = defaultdict(int) self.units = "metric" self.colors = { "background": "#222222", "text": "#FFFFFF", "special": "#FFFF00", "track": "#4DD2FF", } self.special_distance: typing.Dict[str, float] = { "special_distance1": 10, "special_distance2": 20 } self.width = 200 self.height = 300 self.years = YearRange() self.tracks_drawer: typing.Optional["TracksDrawer"] = None self._trans: typing.Optional[typing.Callable[[str], str]] = None self.set_language(None)
def __init__(self) -> None: self._min_length: pint.quantity.Quantity = 1 * Units().km self.special_file_names: typing.List[str] = [] self.year_range = YearRange() self.cache_dir: typing.Optional[str] = None self.strava_cache_file = "" self._cache_file_names: typing.Dict[str, str] = {}
def __init__(self, workers: typing.Optional[int]) -> None: self._workers = workers self._min_length: pint.quantity.Quantity = 1 * Units().km self.special_file_names: typing.List[str] = [] self.year_range = YearRange() self.cache_dir: typing.Optional[str] = None self.strava_cache_file = "" self._cache_file_names: typing.Dict[str, str] = {} self._activity_type: str = "all"
def __compute_years(self, tracks): if self.years is not None: return self.years = YearRange() for t in tracks: self.years.add(t.start_time)
def __init__(self): self.min_length = 1000 self.special_file_names = [] self.year_range = YearRange() self.cache_dir = None self._cache_file_names = {}