Skip to content

Commit

Permalink
ruff fix
Browse files Browse the repository at this point in the history
  • Loading branch information
viktorvaladi committed Oct 21, 2024
1 parent d2423ab commit a388873
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions leakpro/fl_utils/data_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from torch import Tensor, cat, mean, randn, std, tensor
from torch.utils.data import DataLoader, Dataset, TensorDataset


def get_meanstd(trainset: Dataset, axis_to_reduce: tuple=(-2,-1)) -> tuple[Tensor, Tensor]:
"""Get mean and std of a dataset."""
cc = cat([trainset[i][0].unsqueeze(0) for i in range(len(trainset))], dim=0)
Expand Down
4 changes: 1 addition & 3 deletions leakpro/run.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,5 @@
"""Run script."""
import os
from collections import OrderedDict
from typing import Callable, Optional
from typing import Callable

import torch
from torch import Tensor
Expand Down
Empty file removed leakpro/setup.py
Empty file.

0 comments on commit a388873

Please sign in to comment.