Buying AI hardware outright is becoming more economical than renting AI power through the cloud.