I am saving and immediately loading a VarStore for a SequentialModel, but it errors out with Internal torch error: isGenericDict() INTERNAL ASSERT FAILED. I have seen an issue with this happening on the ruby bindings with a model from python, but its odd since I save and load using the rust bindings. The code is just a simple
vs.save("model.bin"); vs.load("model.bin");
but this doesn't work.
Model structure is just one linear layer.
Full stack trace: https://pastebin.com/i8WnJEZ0
Edit: After some testing, it seems this only happens when saving/loading with a file extension bin or pt. If I save with the extension x for example, it loads just fine. Seems it has to do with the Tensor::loadz_multi_with_device function. I normally use the bin extension for binary files, but I'll make it model for now until this is fixed.
I am saving and immediately loading a VarStore for a SequentialModel, but it errors out with
Internal torch error: isGenericDict() INTERNAL ASSERT FAILED
. I have seen an issue with this happening on the ruby bindings with a model from python, but its odd since I save and load using the rust bindings. The code is just a simplevs.save("model.bin"); vs.load("model.bin");
but this doesn't work. Model structure is just one linear layer. Full stack trace: https://pastebin.com/i8WnJEZ0Edit: After some testing, it seems this only happens when saving/loading with a file extension
bin
orpt
. If I save with the extensionx
for example, it loads just fine. Seems it has to do with theTensor::loadz_multi_with_device
function. I normally use thebin
extension for binary files, but I'll make itmodel
for now until this is fixed.