  Determining the presence of a potential optical source in the interest region
is important for an imaging system and can be achieved by using hypothesis
testing. The previous studies assume that the potential source is completely
incoherent. In this paper, this problem is generalized to the scenario with
partially coherent sources and any prior probabilities. We compare the error
probability limit given by the quantum Helstrom bound with the error
probability given by direct decision based on the prior probability. On this
basis, the quantum-optimal detection advantage and detection-useless region are
analyzed. For practical purposes, we propose a specific detection strategy
using binary spatial-mode demultiplexing, which can be used in the scenarios
without any prior information. This strategy shows superior detection
performance and the results hold prospects for achieving super-resolved
microscopic and astronomical imaging.
