21 """ Constructor of the state object """
24 """ Returns representation of this state"""
28 def feature_importance(state):
30 Return a list containing the feature importances
32 print(
"Called feature importance")
36 def get_model(number_of_features, number_of_spectators, number_of_events, training_fraction, parameters):
38 Return default test model
40 print(
"Called get_model")
61 return np.require(p, dtype=np.float32, requirements=[
'A',
'W',
'C',
'O'])
64 def begin_fit(state, Xtest, Stest, ytest, wtest):
66 Test begin_fit function
68 print(
"Called begin_fit")
69 print(state, Xtest.shape, Stest.shape, ytest.shape, wtest.shape)
73 def partial_fit(state, X, S, y, w, epoch):
75 Test partial_fit function
77 print(
"Called partial_fit")
78 print(state, X.shape, S.shape, y.shape, w.shape, epoch)
86 print(
"Called end_fit")
88 return "SerializedState"