Do you need to script this save method? It seems it just stored some numpy arrays to a file to you might write this method manually outside of the model without scripting. Alternatively you could also add the jit.ignore decorator to this method so that it won’t be exported.