GranularWMVFTS
This commit is contained in:
parent
4b07599c43
commit
f63b582b30
@ -8,7 +8,7 @@ from pyFTS.models.multivariate import mvfts, grid, common
|
|||||||
|
|
||||||
class ClusteredMVFTS(mvfts.MVFTS):
|
class ClusteredMVFTS(mvfts.MVFTS):
|
||||||
"""
|
"""
|
||||||
Meta model for multivariate, high order, clustered multivariate FTS
|
Meta model for high order, clustered multivariate FTS
|
||||||
"""
|
"""
|
||||||
def __init__(self, **kwargs):
|
def __init__(self, **kwargs):
|
||||||
super(ClusteredMVFTS, self).__init__(**kwargs)
|
super(ClusteredMVFTS, self).__init__(**kwargs)
|
||||||
|
26
pyFTS/models/multivariate/granular.py
Normal file
26
pyFTS/models/multivariate/granular.py
Normal file
@ -0,0 +1,26 @@
|
|||||||
|
from pyFTS.models.multivariate import cmvfts, grid
|
||||||
|
from pyFTS.models import hofts
|
||||||
|
|
||||||
|
|
||||||
|
class GranularWMVFTS(cmvfts.ClusteredMVFTS):
|
||||||
|
"""
|
||||||
|
Granular multivariate weighted high order FTS
|
||||||
|
"""
|
||||||
|
|
||||||
|
def __init__(self, **kwargs):
|
||||||
|
super(GranularWMVFTS, self).__init__(**kwargs)
|
||||||
|
|
||||||
|
self.fts_method = hofts.WeightedHighOrderFTS
|
||||||
|
self.model = None
|
||||||
|
"""The most recent trained model"""
|
||||||
|
self.knn = kwargs.get('knn', 2)
|
||||||
|
self.order = kwargs.get("order", 2)
|
||||||
|
self.shortname = "GranularWMVFTS"
|
||||||
|
self.name = "Granular Weighted Multivariate FTS"
|
||||||
|
|
||||||
|
def train(self, data, **kwargs):
|
||||||
|
self.partitioner = grid.IncrementalGridCluster(
|
||||||
|
explanatory_variables=self.explanatory_variables,
|
||||||
|
target_variable=self.target_variable)
|
||||||
|
super.train(data,**kwargs)
|
||||||
|
|
Loading…
Reference in New Issue
Block a user