geopm  3.1.1.dev296+g5916b956
GEOPM - Global Extensible Open Power Manager
RegionHintRecommender.hpp
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2015 - 2024 Intel Corporation
3  * SPDX-License-Identifier: BSD-3-Clause
4  */
5 
6 #ifndef REGIONHINTRECOMMENDER_HPP_INCLUDE
7 #define REGIONHINTRECOMMENDER_HPP_INCLUDE
8 
9 #include <memory>
10 #include <map>
11 #include <string>
12 #include <vector>
13 
14 namespace geopm
15 {
20  {
21  public:
31  static std::unique_ptr<RegionHintRecommender> make_unique(const std::string &fmap_path,
32  int min_freq, int max_freq);
42  static std::shared_ptr<RegionHintRecommender> make_shared(const std::string &fmap_path,
43  int min_freq, int max_freq);
44 
45  virtual ~RegionHintRecommender() = default;
54  virtual double recommend_frequency(const std::map<std::string, double> &nn_output,
55  double phi) const = 0;
56  };
57 }
58 
59 #endif /* REGIONHINTRECOMMENDER_HPP_INCLUDE */
Class ingesting the output from a DomainNetMap and a frequency map json file and determining a recomm...
Definition: RegionHintRecommender.hpp:20
virtual ~RegionHintRecommender()=default
static std::shared_ptr< RegionHintRecommender > make_shared(const std::string &fmap_path, int min_freq, int max_freq)
Returns a shared_ptr to a concrete object constructed using the underlying implementation,...
Definition: RegionHintRecommender.cpp:29
virtual double recommend_frequency(const std::map< std::string, double > &nn_output, double phi) const =0
Recommends frequency based on the output from a DomainNetMap neural net evaluation.
static std::unique_ptr< RegionHintRecommender > make_unique(const std::string &fmap_path, int min_freq, int max_freq)
Returns a unique_ptr to a concrete object constructed using the underlying implementation,...
Definition: RegionHintRecommender.cpp:22
Definition: Accumulator.cpp:12