Added PyTorchModelHubMixin for HF
Browse files- megaloc_model.py +2 -1
megaloc_model.py
CHANGED
|
@@ -8,9 +8,10 @@ import torch
|
|
| 8 |
import torch.nn as nn
|
| 9 |
import torch.nn.functional as F
|
| 10 |
import torchvision.transforms as tfm
|
|
|
|
| 11 |
|
| 12 |
|
| 13 |
-
class MegaLocModel(nn.Module):
|
| 14 |
def __init__(
|
| 15 |
self,
|
| 16 |
feat_dim=8448,
|
|
|
|
| 8 |
import torch.nn as nn
|
| 9 |
import torch.nn.functional as F
|
| 10 |
import torchvision.transforms as tfm
|
| 11 |
+
from huggingface_hub import PyTorchModelHubMixin
|
| 12 |
|
| 13 |
|
| 14 |
+
class MegaLocModel(nn.Module, PyTorchModelHubMixin):
|
| 15 |
def __init__(
|
| 16 |
self,
|
| 17 |
feat_dim=8448,
|