| DayF core 1.2.1.2 DayF (Decision at your Fingertips) is an AutoML freeware development framework that let developers works with Machine Learning models without any idea of AI, simply taking a csv dataset and the objective column

Public Member Functions | Public Attributes | List of all members
gdayf.core.controller.Controller Class Reference

Core class oriented to manage the comunication and execution messages pass for all components on system orchestrating the execution of actions activities (train and prediction) on specific frameworks. More...

Inheritance diagram for gdayf.core.controller.Controller:
[legend]
Collaboration diagram for gdayf.core.controller.Controller:
[legend]

## Public Member Functions
def | __init__ (self, e_c=None, user_id='PoC_gDayF', workflow_id='default')
| Constructor.
def | config_checks (self)
| Method leading configurations coherence checks. More...
def | exec_prediction (self, datapath, armetadata=None, model_file=None)
| Method leading and controlling prediction's executions on all frameworks. More...
def | clean_handler (self, fw)
| Method focus on cleaning handler objects. More...
def | init_handler (self, fw)
| Method oriented to init handler objects. More...
def | clean_handlers (self)
| Method oriented to shutdown localClusters.
def | exec_analysis (self, datapath, objective_column, amode=POC, metric='test_accuracy', deep_impact=3, kwargs)
| Method leading and controlling analysis's executions on all frameworks. More...
def | log_model_list (self, ar_list, metric)
| Method oriented to log leaderboard against selected metrics. More...
def | table_model_list (self, ar_list, metric)
| Method oriented to log leaderboard against selected metrics on dataframe. More...
def | exec_sanalysis (self, datapath, list_ar_metadata, metric='combined_accuracy', deep_impact=1, kwargs)
| Method leading and controlling analysis's executions on specific analysis. More...
def | get_external_model (self, armetadata, type='pojo')
| Method leading and controlling coversion to java model. More...
def | save_models (self, arlist, mode=BEST, metric='accuracy')
| Method leading and controlling model savings. More...
def | load_models (self, arlist)
| Method leading and controlling model loads. More...
def | remove_models (self, arlist, mode=ALL)
| Method leading and controlling model removing from server. More...
def | reconstruct_execution_tree (self, arlist=None, metric='combined', store=True)
| Method oriented to generate execution tree for visualizations and analysis issues. More...
def | priorize_list (self, arlist, metric)
| Method oriented to priorize ARlist. More...
def | get_ar_from_engine (self, path)
| Method base to get an ArMetadata Structure from file. More...

## Public Attributes
| timestamp
| analysis_list
| model_handler
| adviser

## Detailed Description

Core class oriented to manage the comunication and execution messages pass for all components on system orchestrating the execution of actions activities (train and prediction) on specific frameworks.

Definition at line 41 of file controller.py.

## Member Function Documentation

## ◆ clean_handler()

def gdayf.core.controller.Controller.clean_handler | ( |  | self,
|  |  | fw
| ) |  |

Method focus on cleaning handler objects.

Parameters

  fw | framework

Definition at line 276 of file controller.py.

Here is the caller graph for this function:

## ◆ config_checks()

def gdayf.core.controller.Controller.config_checks | ( |  | self | ) |

Method leading configurations coherence checks.

Parameters

  self | object pointer

Returns
  True if OK / False if wrong

Definition at line 66 of file controller.py.

Here is the call graph for this function:

## ◆ exec_analysis()

def gdayf.core.controller.Controller.exec_analysis | ( |  | self,
|  |  | datapath,
|  |  | objective_column,
|  |  | amode = `POC`,
|  |  | metric = `'test_accuracy'`,
|  |  | deep_impact = `3`,
|  |  | kwargs
| ) |  |

Method leading and controlling analysis's executions on all frameworks.

Parameters

  self | object pointer
  datapath | String Path indicating file to be analyzed or DataFrame
  objective_column | string indicating objective column
  amode | Analysis mode of execution [0,1,2,3,4,5,6]
  metric | to evalute models ['train_accuracy', 'train_rmse', 'test_accuracy', 'combined_accuracy', 'test_rmse', 'cdistance']
  deep_impact | deep analysis

Returns
  status, adviser.analysis_recommendation_order

Definition at line 321 of file controller.py.

Here is the call graph for this function:

## ◆ exec_prediction()

def gdayf.core.controller.Controller.exec_prediction | ( |  | self,
|  |  | datapath,
|  |  | armetadata = `None`,
|  |  | model_file = `None`
| ) |  |

Method leading and controlling prediction's executions on all frameworks.

Parameters

  self | object pointer
  datapath | String Path indicating file to be analyzed or Dataframe
  armetadata |
  model_file | String Path indicating model_file ArMetadata.json structure

Definition at line 211 of file controller.py.

Here is the call graph for this function:

## ◆ exec_sanalysis()

def gdayf.core.controller.Controller.exec_sanalysis | ( |  | self,
|  |  | datapath,
|  |  | list_ar_metadata,
|  |  | metric = `'combined_accuracy'`,
|  |  | deep_impact = `1`,
|  |  | kwargs
| ) |  |

Method leading and controlling analysis's executions on specific analysis.

Parameters

  self | object pointer
  datapath | String Path indicating file to be analyzed or DataFrame
  list_ar_metadata | list of models to execute
  metric | to evalute models
  deep_impact | deep analysis

Returns
  status, adviser.analysis_recommendation_order

Definition at line 554 of file controller.py.

Here is the call graph for this function:

## ◆ get_ar_from_engine()

def gdayf.core.controller.Controller.get_ar_from_engine | ( |  | self,
|  |  | path
| ) |  |

Method base to get an ArMetadata Structure from file.

Parameters

  self | object pointer
  path | FilePath

Returns
  operation status (0 success /1 error, ArMetadata/None)

Definition at line 834 of file controller.py.

## ◆ get_external_model()

def gdayf.core.controller.Controller.get_external_model | ( |  | self,
|  |  | armetadata,
|  |  | type = `'pojo'`
| ) |  |

Method leading and controlling coversion to java model.

Parameters

  self | object pointer
  armetadata | Armetada object
  type | base type if is possible

Returns
  download_path, hash MD5 key

Definition at line 647 of file controller.py.

Here is the call graph for this function:

## ◆ init_handler()

def gdayf.core.controller.Controller.init_handler | ( |  | self,
|  |  | fw
| ) |  |

Method oriented to init handler objects.

Parameters

  fw | framework

Definition at line 283 of file controller.py.

Here is the caller graph for this function:

## ◆ load_models()

def gdayf.core.controller.Controller.load_models | ( |  | self,
|  |  | arlist
| ) |  |

Method leading and controlling model loads.

Parameters

  self | object pointer
  arlist | List of armetadata

Returns
  list of ar_descriptors of models correctly loaded

Definition at line 688 of file controller.py.

Here is the call graph for this function:

## ◆ log_model_list()

def gdayf.core.controller.Controller.log_model_list | ( |  | self,
|  |  | ar_list,
|  |  | metric
| ) |  |

Method oriented to log leaderboard against selected metrics.

Parameters

  ar_list | List of AR models Execution Data
  metric | to execute order ['train_accuracy', 'train_rmse', 'test_accuracy', 'combined_accuracy', 'test_rmse', 'cdistance']

Definition at line 447 of file controller.py.

Here is the call graph for this function:
Here is the caller graph for this function:

## ◆ priorize_list()

def gdayf.core.controller.Controller.priorize_list | ( |  | self,
|  |  | arlist,
|  |  | metric
| ) |  |

Method oriented to priorize ARlist.

Parameters

  self | object pointer
  analysis_id |
  arlist | Priorized ArMetadata list
  metric | ['accuracy', 'combined', 'test_accuracy', 'rmse']

Returns
  OrderedDict() with execution tree data Analysis

Definition at line 824 of file controller.py.

Here is the caller graph for this function:

## ◆ reconstruct_execution_tree()

def gdayf.core.controller.Controller.reconstruct_execution_tree | ( |  | self,
|  |  | arlist = `None`,
|  |  | metric = `'combined'`,
|  |  | store = `True`
| ) |  |

Method oriented to generate execution tree for visualizations and analysis issues.

Parameters

  arlist | Priorized ArMetadata list
  metric | ['accuracy', 'combined', 'test_accuracy', 'rmse']
  store | True/False
  experiment | analysys_id for mongoDB recovery
  user | user_id for mongoDB recovery

Returns
  OrderedDict() with execution tree data Analysis

Definition at line 740 of file controller.py.

Here is the call graph for this function:

## ◆ remove_models()

def gdayf.core.controller.Controller.remove_models | ( |  | self,
|  |  | arlist,
|  |  | mode = `ALL`
| ) |  |

Method leading and controlling model removing from server.

Parameters

  self | object pointer
  mode | to be keeped in memory [BEST, BEST_3, EACH_BEST, ALL,NONE]
  arlist | List of armetadata

Definition at line 704 of file controller.py.

Here is the call graph for this function:

## ◆ save_models()

def gdayf.core.controller.Controller.save_models | ( |  | self,
|  |  | arlist,
|  |  | mode = `BEST`,
|  |  | metric = `'accuracy'`
| ) |  |

Method leading and controlling model savings.

Parameters

  self | object pointer
  mode | [BEST, BEST_3, EACH_BEST, ALL]
  arlist | List of armetadata
  metric | ['accuracy', 'combined', 'test_accuracy', 'rmse']

Definition at line 659 of file controller.py.

Here is the call graph for this function:

## ◆ table_model_list()

def gdayf.core.controller.Controller.table_model_list | ( |  | self,
|  |  | ar_list,
|  |  | metric
| ) |  |

Method oriented to log leaderboard against selected metrics on dataframe.

Parameters

  analysis_id |
  ar_list | List of AR models Execution Data
  metric | to execute order ['train_accuracy', 'train_rmse', 'test_accuracy', 'combined_accuracy', 'test_rmse', 'cdistance']

Returns
  Dataframe performance model list

Definition at line 495 of file controller.py.

Here is the call graph for this function:

The documentation for this class was generated from the following file:

- D:/OneDrive/DayF/git/gdayf-core/src/gdayf/core/controller.py