title: Where do I get a CPU-only version of PyTorch?
body: <p>I'm trying to get a basic app running with Flask + PyTorch, and host it on Heroku. However, I run into the issue that the maximum slug size is 500mb on the free version, and PyTorch itself is ~500mb. </p>
  
  <p>After some google searching, someone wrote about finding a cpu-only version of PyTorch, and using that, which is much smaller <a href="https://www.codementor.io/akshaysharma17/how-and-why-i-built-an-ml-based-python-api-hosted-on-heroku-j74qbfwn1" rel="noreferrer">here</a>.</p>
  
  <p>However, I'm pretty lost as to how this is done, and the person didn't document this at all. Any advice is appreciated, thanks. </p>
  
  <p>EDIT: </p>
  
  <p>To be more specific about my problem, I tried installing torch by (as far as I understand), including a requirements.txt which listed torch as a dependency. Current I have: torch==0.4.1. However this doesn't work bc of size.</p>
  
  <p>My question is, do you know what I could write in the requirements file to get the cpu-only version of torch that is smaller, or alternatively, if the requirements.txt doesn't work for this, what I would do instead, to get the cpu version. </p>