 In the event of a boom in space resource development there would be an increased amount of space debris making it difficult for existing spacecrafts to navigate safely. To address this issue we have developed a novel context sensing YOLO V5, CSYOLO V5 algorithm which can detect small and weak space objects by extracting local context information and fusing spatial information from multiple layers. We also introduced the cross-layer context fusion module CCFM adaptive weighting module AWM spatial information enhancement module CM and contrast mosaic data augmentation CMD. These modules work together to improve the accuracy of the algorithm and its ability to detect small and weak space objects. Experimental results show that our approach outperforms other state-of-the-art methods in terms of accuracy and robustness. This article was authored by Yumen Yuan, Hong Yang Bai, Pan Feng Wu, and others.