AWS EC g instances versus hardware i9+2x4090

I am a bit confused between spending 1k AUD per month for (AWS EC g, 4CPU with 16GiB graphics memory?) versus building a i9 with 2x4090 (also around 1k per month for a year)? The intention would be to use pytorch for ML. Can someone please advise? Thanks.