In most practical applications, the feature space of the training datasets and the target domain datasets are inconsistent, or the data distribution between them is inconsistent, which leads to the problem of data starvation and makes it difficult for terminal devices to obtain high accurate results. Aiming at the problems of limited terminal device resources, low accuracy of data processing results, and unsatisfactory processing speed, a Heterogeneous Multi-access Edge Computing (MEC) Framework based on Transfer Learning (TL) is proposed, abbreviated as HMECF-TL. This framework adopts a cloud-edge-end three-layer architecture. It uses model transfer to optimize the Convolutional Neural Networks (CNN) model at each layer to achieve the goal of improving data processing speed and accuracy. Furthermore, a multi-agent Deep Reinforcement Learning Algorithm having Attention Mechanism (DRLAAM) is designed to further increase the timeliness performance of computation-intensive applications. The performance of HMECSF-TL framework is verified by simulation experiments, which not only reduces the delay by more than 24.66 %, but also improves the accuracy by more than 8.34 %. The framework not only increase the computing capacity to solve the shortage of terminal device resources, but also improve the quality of data processing to solve the problem of data starvation.