Maximum likelihood estimators for inverse problems with nuisance parameters