Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove sparse test collection warning #489

Merged
merged 3 commits into from
Jul 9, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions test/sparsity/test_fast_sparse_training.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
)
from torchao.utils import TORCH_VERSION_AFTER_2_4, is_fbcode

class TestModel(nn.Module):
class ToyModel(nn.Module):
def __init__(self):
super().__init__()
self.linear1 = nn.Linear(128, 256, bias=False)
Expand All @@ -36,7 +36,7 @@ def test_runtime_weight_sparsification(self):
from torch.sparse import SparseSemiStructuredTensorCUSPARSELT
input = torch.rand((128, 128)).half().cuda()
grad = torch.rand((128, 128)).half().cuda()
model = TestModel().half().cuda()
model = ToyModel().half().cuda()
model_c = copy.deepcopy(model)

for name, mod in model.named_modules():
Expand Down Expand Up @@ -77,7 +77,7 @@ def test_runtime_weight_sparsification_compile(self):
from torch.sparse import SparseSemiStructuredTensorCUSPARSELT
input = torch.rand((128, 128)).half().cuda()
grad = torch.rand((128, 128)).half().cuda()
model = TestModel().half().cuda()
model = ToyModel().half().cuda()
model_c = copy.deepcopy(model)

for name, mod in model.named_modules():
Expand Down
Loading