codars
commented
Feb 13, 2020
Read more
Computer vision is an interdisciplinary field that deals with how computers can be made to gain high-level understanding of digital images and videos.
Change tensor.data to tensor.detach() due to
pytorch/pytorch#6990 (comment)
tensor.detach() is more robust than tensor.data.
Current pytorch implementation ignores the argument split_f in the function train_batch_ch13 as shown below.
def train_batch_ch13(net, X, y, loss, trainer, devices):
if isinstance(X, list):
# Required for BERT Fine-tuning (to be covered later)
X = [x.to(devices[0]) for x in X]
else:
X = X.to(devices[0])
...Todo: Define the argument `
The operators in functional_tensor.py perform casting in two ways:
tensor.to(dtype=dtype) PyTorch methodconvert_image_dtype() Transformation methodThe first method does direct casting from one type to the other. The latter method has mo