| 
									
										
										
										
											2019-07-11 13:56:52 +08:00
										 |  |  | //
 | 
					
						
							|  |  |  | //  CPUPoolInt8.hpp
 | 
					
						
							|  |  |  | //  MNN
 | 
					
						
							|  |  |  | //
 | 
					
						
							|  |  |  | //  Created by MNN on 2019/06/10.
 | 
					
						
							|  |  |  | //  Copyright © 2018, Alibaba Group Holding Limited
 | 
					
						
							|  |  |  | //
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #ifndef CPUPoolInt8_hpp
 | 
					
						
							|  |  |  | #define CPUPoolInt8_hpp
 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-12-27 22:16:57 +08:00
										 |  |  | #include "backend/cpu/CPUBackend.hpp"
 | 
					
						
							| 
									
										
										
										
											2019-07-11 13:56:52 +08:00
										 |  |  | 
 | 
					
						
							|  |  |  | namespace MNN { | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | class CPUPoolInt8 : public Execution { | 
					
						
							|  |  |  | public: | 
					
						
							|  |  |  |     CPUPoolInt8(Backend *b, const Pool *parameter); | 
					
						
							|  |  |  |     virtual ~CPUPoolInt8() = default; | 
					
						
							|  |  |  |     virtual ErrorCode onResize(const std::vector<Tensor *> &inputs, const std::vector<Tensor *> &outputs) override; | 
					
						
							|  |  |  |     virtual ErrorCode onExecute(const std::vector<Tensor *> &inputs, const std::vector<Tensor *> &outputs) override; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | private: | 
					
						
							|  |  |  |     const Pool *mParameter; | 
					
						
							| 
									
										
										
										
											2019-12-20 18:13:16 +08:00
										 |  |  |     std::function<void(const Tensor *src, Tensor *dst)> mThreadFunction; | 
					
						
							|  |  |  |     // nhwc buffer
 | 
					
						
							|  |  |  |     std::shared_ptr<Tensor> mInputTemp; | 
					
						
							|  |  |  |     std::shared_ptr<Tensor> mOutputTemp; | 
					
						
							| 
									
										
										
										
											2019-07-11 13:56:52 +08:00
										 |  |  | }; | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | } // namespace MNN
 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | #endif /* CPUPoolInt8_hpp */
 |