-
-
Notifications
You must be signed in to change notification settings - Fork 15.4k
python3Packages.tensorboardx: fix build after upgrade to PyTorch 1.6 #97261
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
python3Packages.tensorboardx: fix build after upgrade to PyTorch 1.6 #97261
Conversation
4d293eb
to
9ff9e3a
Compare
2 months passed and we still have broken tensorboardX in master. |
9ff9e3a
to
16273d2
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
otherwise LGTM
https://github.com/NixOS/nixpkgs/pull/97261
2 packages built:
python37Packages.tensorboardx python38Packages.tensorboardx
postPatch = '' | ||
substituteInPlace tensorboardX/pytorch_graph.py --replace "torch.onnx.set_training(model, False)" "torch.onnx.select_model_mode_for_export(model, torch.onnx.TrainingMode.EVAL)" | ||
''; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for readability
postPatch = '' | |
substituteInPlace tensorboardX/pytorch_graph.py --replace "torch.onnx.set_training(model, False)" "torch.onnx.select_model_mode_for_export(model, torch.onnx.TrainingMode.EVAL)" | |
''; | |
postPatch = '' | |
substituteInPlace tensorboardX/pytorch_graph.py \ | |
--replace "torch.onnx.set_training(model, False)" \ | |
"torch.onnx.select_model_mode_for_export(model, torch.onnx.TrainingMode.EVAL)" | |
''; |
does bumping this to 2.1 fix this? |
See |
16273d2
to
0223525
Compare
@ofborg build python37Packages.tensorboardx python38Packages.tensorboardx |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Result of nixpkgs-review pr 97261 1
2 packages built:
- python37Packages.tensorboardx
- python38Packages.tensorboardx
Motivation for this change
Torch ONNX api changed a bit in 1.6 version. TensorboardX build fails now.
Things done
Tweaked code a bit so test works again.
nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
./result/bin/
)nix path-info -S
before and after)