There is a lot of nasty toxin and chemicals in carpet from how they are made and the backing, I wouldn't want that in a pet cage at all, especially not where it would be heated and wet. Having seen a lot of pretty gory cuts and deaths from strings and loops on towels or fabric, I also would not recommend that for a reptile. Plus the bacteria factor with wet fabric, nope, nothing about this is safe. Paper towels or newspaper if you don't want substrate. Tubs are easier because you can just run heat underneath, they hold humidity and you can control the amount of ventilation. In a glass tank if you are using a heat lamp you will have nothing but struggles and the fixes aren't great. Most people close off the top more but then you have a snake in what's likely a too wet or too dry or unstably both environment with unsteady heat and poor air flow. Viola! Respiratory infection. Don't waste your money and time on a fish tank setup unless you want to fill it with water. Get a suitable snake cage and you'll both be much happier.