Roadside sensing units’ (RSUs) perception capability may be substantially impaired by occlusion issue even they work cooperatively. However, the joint influence of static and dynamic occlusions in real‐life situations remains inadequately considered in optimizing RSUs’ placement. This study proposes a virtual‐real‐fusion simulation (VRFS) framework that combines traffic simulation and point clouds of real‐world road environment to optimize RSUs’ deployment. Point clouds and triangular meshes are used to model static and dynamic obstacles, respectively. A structure‐retained spherical projection method is developed to efficiently emulate RSUs’ data collection. Based on the developed VRFS, the probabilistic occupancy maps (POM) are created to represent traffic scenarios. The POM‐based cross entropy (CE) is proposed as the surrogate metric for evaluating the detection performance of cooperative RSUs. The Bayesian optimizer is applied to optimize the RSUs’ placement parameters (decision variables) by minimizing CE. Test results show that it is viable to use the POM‐based CE as a proxy for evaluating cooperative RSUs’ sensing performance. Considering the occlusion effect adds to the efficacy of POM‐based CE as a surrogate metric. Compared with traffic volume, the adverse effect of the proportion of large vehicles on RSUs’ detection performance is more significant. There are no significant patterns regarding how the optimized RSU positions vary with traffic parameters. The comparisons with existing methods further verify the importance of considering both static and dynamic occlusions in optimizing RSUs’ placement. Besides, the proposed method can yield better optimization results more efficiently than existing approaches.