Skip to content

Commit

Permalink
Updates
Browse files Browse the repository at this point in the history
  • Loading branch information
boykovdn committed Jul 20, 2024
1 parent d6e739d commit 3ce5327
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
8 changes: 7 additions & 1 deletion quarto/notes.qmd
Original file line number Diff line number Diff line change
Expand Up @@ -126,5 +126,11 @@ Still, the memory usage spikes to about 10Gb RAM for saving the model.
Looks like the dataset might work any moment now. Project left at running pre-commit. I've already made an initial commit. Might need to relax some pre-commit checks.

:::{.callout-note}
What are library stubs, and how do I install them? Why do I need them?
What are library stubs, and how do I install them? Why do I need them? For now I just tell mypy not to ignore missing imports.
:::

Ok, the dataset can now be served, it seems. There are still some ends to tie up in that code, but let's leave it for now, it looks like it works correctly.

#### Model and training loop

Now let's build the graph wavenet model. I will first adapt my existing code, which implements the forward and backward diffusions, but not the adaptive adjacency matrix.
1 change: 0 additions & 1 deletion src/gwnet/datasets/metrla.py
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,6 @@ def _get_targets_and_features(

def process(self) -> None:
# Read data into huge `Data` list.
# TODO
node_ids, id_to_idx_map, adj = pd.read_pickle(self.raw_paths[1])
edges = torch.from_numpy(self._get_edges(adj))
edge_weights = torch.from_numpy(self._get_edge_weights(adj))
Expand Down
4 changes: 4 additions & 0 deletions tests/metrla/test_creation.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,3 +4,7 @@
class TestMETRLA:
def test_metrla_instantiate(self):
METRLA("./data")

def test_metrla_read(self):
dataset = METRLA("./data")
dataset[0]

0 comments on commit 3ce5327

Please sign in to comment.