Event-based Photometric Bundle Adjustment