Skip to content

Commit

Permalink
refactored
Browse files Browse the repository at this point in the history
  • Loading branch information
kingsleynweye committed Nov 7, 2024
1 parent 0976334 commit 8ddd454
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions citylearn/data.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,7 @@ def get_dataset(self, name: str, directory: Union[Path, str] = None) -> str:
# check that dataset does not already exist using the schema as a proxy
if not os.path.isfile(schema_filepath):
LOGGER.info(f'The {name} dataset DNE in cache. Will download from '
f'{self.github_account}/{self.repository}/tree/v{self.tag} GitHub repository and write to {datasets_directory}. '
f'{self.github_account}/{self.repository}/tree/{self.tag} GitHub repository and write to {datasets_directory}. '
f'Next time DataSet.get_dataset(\'{name}\') is called, it will read '
'from cache unless DataSet.clear_cache is run first.')
contents = self.get_github_contents(path)
Expand Down Expand Up @@ -173,7 +173,7 @@ def get_dataset_names(self) -> List[str]:

else:
LOGGER.info(f'The dataset names DNE in cache. Will download from '
f'{self.github_account}/{self.repository}/tree/v{self.tag} GitHub repository and write to {filepath}. '
f'{self.github_account}/{self.repository}/tree/{self.tag} GitHub repository and write to {filepath}. '
'Next time DataSet.get_dataset_names is called, it will read '
'from cache unless DataSet.clear_cache is run first.')
contents = [
Expand Down Expand Up @@ -203,7 +203,7 @@ def get_pv_sizing_data(self) -> pd.DataFrame:
# check that file DNE
if not os.path.isfile(filepath):
LOGGER.info(f'The PV sizing data DNE in cache. Will download from '
f'{self.github_account}/{self.repository}/tree/v{self.tag} GitHub repository and write to {misc_directory}. '
f'{self.github_account}/{self.repository}/tree/{self.tag} GitHub repository and write to {misc_directory}. '
'Next time DataSet.get_pv_sizing_data is called, it will read '
'from cache unless DataSet.clear_cache is run first.')
contents = self.get_github_contents(path)
Expand Down Expand Up @@ -236,7 +236,7 @@ def get_battery_sizing_data(self) -> Mapping[str, Union[float, str]]:
# check that file DNE
if not os.path.isfile(filepath):
LOGGER.info(f'The battery sizing data DNE in cache. Will download from '
f'{self.github_account}/{self.repository}/tree/v{self.tag} GitHub repository and write to {misc_directory}. '
f'{self.github_account}/{self.repository}/tree/{self.tag} GitHub repository and write to {misc_directory}. '
'Next time DataSet.get_battery_sizing_data is called, it will read '
'from cache unless DataSet.clear_cache is run first.')
contents = self.get_github_contents(path)
Expand Down

0 comments on commit 8ddd454

Please sign in to comment.