pytorchstreamreader failed reading zip archive: failed finding central directory

When working with TorchScript on mobile, you may encounter this error. The issue is likely because the pre-trained model was saved with torch.save() while TorchScript on mobile can only load one saved with torch.jit.save.

The solution is to make your model compatible with TorchScript (Torchscript docs), then save that via torch.jit.save.


More Articles

How to start a new Github repo from an existing project

Assume that you have a project and you want to track it with Github. Navigate to the project folder,...

codezilla

codezilla

How to check for listening ports in Linux

Here is one of the most popular commands for troubleshooting network or specific application problem...

codezilla

codezilla

How to get octal file permissions from command line?

Sometimes we want to know the octal number representing the permission of a file like 755, 777, 664 ...

codezilla

codezilla