## 6 Conclusions  
This paper addresses on the problem of the poor performance of model parallel training caused by a single optimization aspect, and proposes the Trinity method, which uses reinforcement learning to achieve the automatic search and tuning of parallel algorithms for large-scale complex neural network models. Furthermore, this paper constructs a three-dimensional collaborative optimization evaluation model to guide reinforcement learning iterative optimization, and improves the comprehensive performance in terms of the runtime, communication load and memory consumption. A simulator is also introduced to improve the sampling efficiency and accelerate the policy search time. Our experiments use CIFAR10 and PTB datasets based on Inception, NMT, NASNet (large) and PNASNet (large) models. The result shows that, compared with the hierarchical method, Trinity can achieve the performance load balancing with less memory overhead in exchange for performing the optimization of runtime and communication costs.  
Conceptualization, J.Z., Y.Z. ([PERSON]) and Y.R.; methodology, Y.Z. ([PERSON]); supervision, Y.Z. ([PERSON]); project administration, Y.Z. ([PERSON]); software, J.W.; data curation, Y.Z. ([PERSON]) and J.W. All authors have read and agreed to the published version of the manuscript.  
\begin{table}
\begin{tabular}{c c c c c c c} \hline \hline  & \multicolumn{3}{c}{**Search Time (1000 Iterations)**} & \multicolumn{3}{c}{**Percentage Decrease**} \\ \hline
**Network** & **GPUS** & **Hierarchical** & **Trinity** & **Runtime** & **Communication** & **Memory** & **Search Time** \\ \hline InceptionV3 (64) & 2 & 1.2 K & 0.7 K & 0.0\% & 6.8\% & **8.6\%** & **41.7\%** \\  & 4 & 3.6 K & 2.0 K & 0.0\% & \(-\)0.8\% & **43.4\%** & **44.4\%** \\ GNMT & 2 & 18.9 K & 8.9 K & **5.1\%** & **16.1\%** & \(-\)18.8\% & **52.9\%** \\
2 layer (64) & 4 & 20.6 K & 9.8 K & \(-\)5.0\% & \(-\)7.1\% & \(-\)14.6\% & **52.4\%** \\ NMT & 2 & 27.8 K & 10.3 K & **8.3\%** & **20.9\%** & \(-\)4.5\% & **62.9\%** \\
2-layers (64) & 4 & 30.5 K & 17.1 K & **4.1\%** & **14.7\%** & \(-\)0.3\% & **43.9\%** \\ NasNet-L (8) & 2 & 12.5 K & 9.8 K & **1.6\%** & **12.5\%** & **20.0\%** & **21.6\%** \\
4 & 12.6 K & 9.1 K & 0.0\% & **1.6\%** & **2.7\%** & **27.8\%** \\ NasNet-L (32) & 4 & 21.6 K & 16.6 K & - & - & - & **23.1\%** \\ PNASNet-L (8) & 2 & 18.6 K & 18.7 K & **9.0\%** & **13.8\%** & 0.0\% & \(-\)0.5\% \\
4 & 28.8 K & 20.1 K & **7.6\%** & **60.2\%** & \(-\)40.0\% & **30.2\%** \\ \hline \hline \end{tabular}
\end{table}
Table 5: The comparison of the parallel performance improvement rate and search time.  
Figure 9: Trinity algorithm convergence analysis. The \(x\) axis represents the simulation value and the \(y\) axis represents real value.  
**Funding:** This research was funded by National Natural Science Foundation of China OF FUNDER grant number 62072146; The Key Research and Development Program of Zhejiang Province under Grant OF FUNDER grant number 2019C01059; The Key Research and Development Program of Zhejiang Province under Grant OF FUNDER grant number 2019C03135; The Key Research and Development Program of Zhejiang Province under Grant OF FUNDER grant number 2019C03134; National Natural Science Foundation of China OF FUNDER grant number 61972376; National Natural Science Foundation of China OF FUNDER grant number 62072431.  
**Informed Consent Statement:** Not applicable.  
**Data Availability Statement:** Not applicable.  
**Conflicts of Interest:** The authors declare no conflict of interest.