so I (knock on wood) haven't had this happen to me yet so I'm not 100% certain if this will fix it, but you can try wiping them down with a vinegar solution to see if that helps kill the mildew/mold. Moving to Singapore the humidity was one of the HUGE concerns I had around my leather goods and all of my cabinets have "dehumidifiers" on all of the shelves like these - https://www.amazon.com/Damprid-Moisture-Absorber-Lavender-Vanilla/dp/B00ESJAC6Q/ref=sr_1_7?ie=UTF8&qid=1480727175&sr=8-7&keywords=moisture+absorber - I use non-scented ones, these were just the first I found on amazon. So far I've had no issues with any of my stuff... you can get them in big sachet form and on hangers too to put in dressers and in your closet to keep humidity at bay and protect your clothing/accessories.
The carpet removal is huge! We had a similar bad smell and that helped a lot. So did getting the air vents professionally cleaned if you have forced air (i know the jury is out on if this helps air quality, but for us, it helped with lingering smells a lot!).
This stuff will also help in the basement for damp smells. Just keep it far away from kids and pets. https://www.amazon.com/DampRid-FG01FSLV33C-Moisture-Absorber-Eliminator/dp/B00ESJAC6Q/ref=sr_1_3?dchild=1&keywords=basement+damp&qid=1603463004&sr=8-3