MCPcopy Index your code
hub / github.com/lazyprogrammer/machine_learning_examples / partial_fit

Method partial_fit

rl2/mountaincar/pg_tf.py:96–109  ·  view source on GitHub ↗
(self, X, actions, advantages)

Source from the content-addressed store, hash-verified

94 self.session = session
95
96 def partial_fit(self, X, actions, advantages):
97 X = np.atleast_2d(X)
98 X = self.ft.transform(X)
99
100 actions = np.atleast_1d(actions)
101 advantages = np.atleast_1d(advantages)
102 self.session.run(
103 self.train_op,
104 feed_dict={
105 self.X: X,
106 self.actions: actions,
107 self.advantages: advantages,
108 }
109 )
110
111 def predict(self, X):
112 X = np.atleast_2d(X)

Callers

nothing calls this directly

Calls 2

transformMethod · 0.45
runMethod · 0.45

Tested by

no test coverage detected