mirror of
https://github.com/ANL-CEEESA/MIPLearn.git
synced 2025-12-06 09:28:51 -06:00
Remove EnforceOverrides
This commit is contained in:
@@ -5,20 +5,18 @@
|
||||
from typing import Any, List, TYPE_CHECKING, Tuple, Dict, Hashable, Optional
|
||||
|
||||
import numpy as np
|
||||
from overrides import EnforceOverrides
|
||||
from p_tqdm import p_umap
|
||||
|
||||
from miplearn.features import Sample
|
||||
from miplearn.instance.base import Instance
|
||||
from miplearn.types import LearningSolveStats
|
||||
|
||||
from p_tqdm import p_umap
|
||||
|
||||
if TYPE_CHECKING:
|
||||
from miplearn.solvers.learning import LearningSolver
|
||||
|
||||
|
||||
# noinspection PyMethodMayBeStatic
|
||||
class Component(EnforceOverrides):
|
||||
class Component:
|
||||
"""
|
||||
A Component is an object which adds functionality to a LearningSolver.
|
||||
|
||||
|
||||
@@ -6,8 +6,6 @@ import logging
|
||||
from abc import ABC, abstractmethod
|
||||
from typing import Any, List, Optional, Hashable, TYPE_CHECKING
|
||||
|
||||
from overrides import EnforceOverrides
|
||||
|
||||
from miplearn.features import Sample
|
||||
from miplearn.types import VariableName, Category
|
||||
|
||||
@@ -18,7 +16,7 @@ if TYPE_CHECKING:
|
||||
|
||||
|
||||
# noinspection PyMethodMayBeStatic
|
||||
class Instance(ABC, EnforceOverrides):
|
||||
class Instance(ABC):
|
||||
"""
|
||||
Abstract class holding all the data necessary to generate a concrete model of the
|
||||
proble.
|
||||
|
||||
@@ -7,8 +7,6 @@ from abc import ABC, abstractmethod
|
||||
from dataclasses import dataclass
|
||||
from typing import Any, Dict, List, Optional
|
||||
|
||||
from overrides import EnforceOverrides
|
||||
|
||||
from miplearn.features import Constraint, VariableFeatures, ConstraintFeatures
|
||||
from miplearn.instance.base import Instance
|
||||
from miplearn.types import (
|
||||
@@ -47,7 +45,7 @@ class MIPSolveStats:
|
||||
mip_warm_start_value: Optional[float] = None
|
||||
|
||||
|
||||
class InternalSolver(ABC, EnforceOverrides):
|
||||
class InternalSolver(ABC):
|
||||
"""
|
||||
Abstract class representing the MIP solver used internally by LearningSolver.
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user