I have social anxiety but have been going to the gym for two years now, and was too scared/overwhelmed to workout before when I was 220 pounds. You do have to convince yourself the other people don't care (they don't), but what helped me was gradually getting more comfortable with mini goals.
Start using free weights and machines when it's slower for a few sets and then go back to cardio. Then set goals to do more sets even with other people around. Listen to music or a podcast and focus on the workout. I try to stay on my phone to keep me from getting distracted or worrying about what other people are doing between my sets.
You could also find a gym with more a bigger variety of people. I go to community centre gyms, and it's less intimidating when there is a mix of people / experience levels / body types / goals working out at my gym then a gym filled with muscle bros.