Ummm... if it only happens when the bike is upside down, maybe you could check on how well your jockey pulley is spinning? Or if the weight of the chain is tweaking the derailleur arm when the bike is upside down?

But if it only happens when the bike is upside down, I have to wonder how often you ride upside down?