-
Notifications
You must be signed in to change notification settings - Fork 9
整个方案能否导出为onnx格式? #6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
感谢!理论上可行,但导出onnx格式模型并不在团队计划之中,您可自行探索 👍 |
你好,我尝试在test.py 中断点,使用torch.onnx.export(model.clip_model, img, "test.onnx")成功导出,只是文件有600M大小,与您提供的pretrained_all.pth文件40M,相去甚远。 尽管验证onnx时也像是正确的,就是耗时有点多,有没有可能把导出的文件搞小一点,以跑得更快些? |
您好!这是因为保存的模型只包含额外训练参数,不包含预训练CLIP模型。在您导出onnx模型时,预训练CLIP模型也会随之导出,所以整体模型文件较大。 |
@Kaze816 我也尝试导出作者的onnx模型,但是似乎有不支持的模块,请问您导出时有做额外的结构修改吗 |
我只是简单地把最后一步的推理适当地简化了一下。它这整个方案的对纹理类的比较有效果,但对screw类目标类的,效果欠佳 |
首先感谢作者们能够开源这么优秀的网络模型!!!
现有一个问题请教一下,如果想付诸实用,希望模型能导出为onnx格式,不知道有无可能?具体如何操作呀?
PS:先前在学习AnomalyCLIP时,文 / 图两个部分始终没能合在一起,就搞得需要自己动手写后处理,既麻烦,还容易出错。
The text was updated successfully, but these errors were encountered: