Resize a Tensor in PyTorch
Class in Python
Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!
@abstractmethod, @staticmethod, abstract class, etc.
override,
prefer classmethod to static method;
both class and static methods can be override
Meta Class
https://stackoverflow.com/questions/100003/what-are-metaclasses-in-python
It seems to me …
Save and Load PyTorch Models
Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!
-
PyTorch uses pickle to serialize and deserialize objects.
-
The PyTorch convention is to use the file extension
.ptor.pthfor saving model (or its parameters) and use the file extension …
General Tips for Gradle
Things on this page are fragmentary and immature notes/thoughts of the author. Please read with your own judgement!
Install & Upgrade Gradle
The latest version of gradle can be installed via PPA on Ubuntu.
sudo add-apt-repository ppa:cwchien/gradle
sudo apt-get update
And gradle can be upgraded using the following …