Industry leader Core Scientific is likely to file for bankruptcy by the end of the year, but other mining companies are in trouble as well