Might be a swim bladder problem. Not much you can do. Try target feeding the fish some food mixed with Kanaplex + a pinch of plain USP epsom salts + Focus and RODI as needed to bind it all together.
My barbonis did the same thing after a tank switch over. It’s been swimming upside down for weeks with no problems, but are getting better now with occasionally doing the upside thing.