Skip to content

Commit 6ead9c5

Browse files
vincentkoppenThijss
authored andcommitted
chore: remove unused/nonfunctional cache on graphcontainer (#30)
Signed-off-by: Vincent Koppen <[email protected]>
1 parent a6f0681 commit 6ead9c5

File tree

1 file changed

+0
-10
lines changed

1 file changed

+0
-10
lines changed

src/power_grid_model_ds/_core/model/graphs/container.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@
66

77
import dataclasses
88
from dataclasses import dataclass
9-
from pathlib import PosixPath
109
from typing import Generator
1110

1211
import numpy as np
@@ -119,15 +118,6 @@ def make_inactive(self, branch: BranchArray) -> None:
119118
graph.delete_branch(from_ext_node_id=from_node, to_ext_node_id=to_node)
120119
setattr(self, field.name, graph)
121120

122-
def cache(self, cache_dir: PosixPath, compress: bool) -> PosixPath:
123-
"""Cache the container into a folder with .pkl and graph files"""
124-
cache_dir.mkdir(parents=True, exist_ok=True)
125-
126-
for field in self.graph_attributes:
127-
graph = getattr(self, field.name)
128-
graph.cache(cache_dir=cache_dir, graph_name=field.name, compress=compress)
129-
return cache_dir
130-
131121
@classmethod
132122
def from_arrays(cls, arrays: MinimalGridArrays) -> "GraphContainer":
133123
"""Build from arrays"""

0 commit comments

Comments
 (0)