DIY - would try taking the bend out of the derailleur hanger/drop out in a vice w/hardwood inserts, but may take a lot of force,
would probably put some (blow torch) heat at the bend prior to trying to flatten too.
It does not look replaceable ? (a side picture towards bike would clarify)