This repository contains attempts to adapt the PyTorch autotagger model in TensorflowJS + Node environment. You can see more details in the paper on Habr.com.
- Exporting *.pth file to ONNX (
torch.onnx.export(learn.eval().to('cuda'), torch.randn(1, 3, 224, 224).to('cuda'), "danbooru.onnx")
) - Using onnx-tf:
$ onnx-tf convert -i danbooru.onnx -o danbooru
- Next stage is converting *.pb to a package for browsers, but I failed it. :( BTW *.pb model is good for my Electron pet project so I don't care about that.
- Node 16
- Python 3.9
- fastbook 0.0.26
- scipy 1.8.1