Update app.py
Browse files
app.py
CHANGED
@@ -19,7 +19,7 @@ class Net(nn.Module):
|
|
19 |
def forward(self,x):
|
20 |
return self.layer(x)
|
21 |
|
22 |
-
@st.cache
|
23 |
def GetModelAndTokenizer():
|
24 |
model = Net()
|
25 |
model.load_state_dict(torch.load('model.dat', map_location=torch.device('cpu')))
|
|
|
19 |
def forward(self,x):
|
20 |
return self.layer(x)
|
21 |
|
22 |
+
@st.cache(allow_output_mutation=True)
|
23 |
def GetModelAndTokenizer():
|
24 |
model = Net()
|
25 |
model.load_state_dict(torch.load('model.dat', map_location=torch.device('cpu')))
|