While impossible to eliminate comparison altogether, minimizing the exposure to comparison triggers, like social media, can certainly help. Also, intentionally practicing a positive comparison, by verbalizing what your body is better at, can help rewiring your brain to think differently.
Get into a habit of giving a positive praise to your body. Instead of focusing on the success of the outcome, appreciate the hard work you body does in the process. Instead of punishing the wrong things, reinforce the right right ones.