chaiNNer-org / spandrel

Spandrel gives your project support for various PyTorch architectures meant for AI Super-Resolution, restoration, and inpainting. Based on the model support implemented in chaiNNer.
MIT License
105 stars 7 forks source link

Add `dtype`, `cpu`, and `cuda` to model API #132

Closed RunDevelopment closed 5 months ago

RunDevelopment commented 5 months ago

This adds the cpu and cuda methods to make it easier to move the model to a different device. I also added a dtype property to make it easier to convert tensors to the same dtype as the model.

This is preparation for fixing to.