xref: /aosp_15_r20/external/pytorch/torch/csrc/jit/backends/coreml/cpp/context.h (revision da0073e96a02ea20f0ac840b70461e3646d07c45)
1 #ifndef PTM_COREML_Context_h
2 #define PTM_COREML_Context_h
3 
4 #include <atomic>
5 #include <string>
6 
7 namespace torch {
8 namespace jit {
9 namespace mobile {
10 namespace coreml {
11 
12 struct ContextInterface {
13   virtual ~ContextInterface() = default;
14   virtual void setModelCacheDirectory(std::string path) = 0;
15 };
16 
17 class BackendRegistrar {
18  public:
19   explicit BackendRegistrar(ContextInterface* ctx);
20 };
21 
22 void setModelCacheDirectory(std::string path);
23 
24 } // namespace coreml
25 } // namespace mobile
26 } // namespace jit
27 } // namespace torch
28 
29 #endif
30