Targeted at the current issues of communication delay, data congestion, and data redundancy in cloud computing for medical big data, a fog computing optimization model is designed, namely an intelligent front-end architecture of fog computing. It uses the network structure characteristics of fog computing and “decentralized and local” mind-sets to tackle the current medical IoT network’s narrow bandwidth, information congestion, heavy computing burden on cloud services, insufficient storage space, and poor data security and confidentiality. The model is composed of fog computing, deep learning, and big data technology. By full use of the advantages of WiFi and user mobile devices in the medical area, it can optimize the internal technology of the model, with the help of classification methods based on big data mining and deep learning algorithms based on artificial intelligence, and automatically process case diagnosis, multi-source heterogeneous data mining, and medical records. It will also improve the accuracy of medical diagnosis and the efficiency of multi-source heterogeneous data processing while reducing network delay and power consumption, ensuring patient data privacy and safety, reducing data redundancy, and reducing cloud overload. The response speed and network bandwidth of the system have been greatly optimized in the process, which improves the quality of medical information service.