Torch.from_numpy(im.copy()).to(device) takes time

Hi AlphaBetaGamma96,

Just tried and got error as below. I’ll try to find the reason.
Here it is:

im = torch.as_tensor(im, device=model.device)

ValueError: At least one stride in the given numpy array is negative, and tensors with negative strides are not currently supported. (You can probably work around this by making a copy of your array with array.copy().)

Best Regards, Yuji