Spaces:
Build error
Build error
Update app.py
Browse files13 unmodified lines1415161718192013 unmodified linesmodel = resnet50(pretrained=True)model.fc = torch.nn.Linear(model.fc.in_features, 2) # 2 classes: bullish and bearishtry:state_dict = torch.load('/Users/kaylahoffman/Desktop/full_model.pt', map_location=torch.device('cpu'))model.load_state_dict(state_dict)st.success("Model loaded successfully!")except Exception as e:13 unmodified lines1415161718192013 unmodified linesmodel = resnet50(pretrained=True)model.fc = torch.nn.Linear(model.fc.in_features, 2) # 2 classes: bullish and bearishtry:state_dict = torch.load('/Users/kaylahoffman/Desktop/stock_prediction_model.h5', map_location=torch.device('cpu'))model.load_state_dict(state_dict)st.success("Model loaded successfully!")except Exception as e:
app.py+1-1