This is the first release of `cloud_resource_matcher`, a framework for cloud cost optimization.
It provides modules for the [`optiframe`](https://github.com/TimJentzsch/optiframe) optimization framework to allow you to model your cloud infrastructure and obtain a cost-optimal solution.
You can install it via `pip install cloud_resource_matcher`.
You should install `optiframe` and [`pulp`](https://github.com/coin-or/pulp) as well.
Afterwards, you can use it as follows:
py
from pulp import LpMinimize
from optiframe import Optimizer, SolutionObjValue
from cloud_resource_matcher.modules.base import BaseData, BaseSolution, base_module
from cloud_resource_matcher.modules.performance import PerformanceData, performance_module
Specify the data of the problem instance
base_data = BaseData(...)
performance_data = PerformanceData(...)
solution = (
Optimizer("cloud_cost_optimization", sense=LpMinimize)
Configure which modules you want to use
.add_modules(base_module, performance_module)
Add the data of the problem instance
.initialize(base_data, performance_data)
Obtain the optimal solution to the problem
.solve()
)
Extract the total cost of the solution
cost = solution[SolutionObjValue].objective_value
Determine which cloud resource should be matched to which cloud service
matching = solution[BaseSolution]