MCPcopy Index your code
hub / github.com/shenweichen/GraphEmbedding / train

Method train

ge/models/line.py:212–233  ·  view source on GitHub ↗
(self, batch_size=1024, epochs=1, initial_epoch=0, verbose=1, times=1)

Source from the content-addressed store, hash-verified

210 return self._embeddings
211
212 def train(self, batch_size=1024, epochs=1, initial_epoch=0, verbose=1, times=1):
213 self.reset_training_config(batch_size, times)
214 try:
215 hist = self.model.fit(
216 self.batch_it,
217 epochs=epochs,
218 initial_epoch=initial_epoch,
219 steps_per_epoch=self.steps_per_epoch,
220 verbose=verbose,
221 )
222 except TypeError:
223 if not hasattr(self.model, "fit_generator"):
224 raise
225 hist = self.model.fit_generator(
226 self.batch_it,
227 epochs=epochs,
228 initial_epoch=initial_epoch,
229 steps_per_epoch=self.steps_per_epoch,
230 verbose=verbose,
231 )
232
233 return hist

Callers 2

test_LINEFunction · 0.95
mainFunction · 0.95

Calls 1

reset_training_configMethod · 0.95

Tested by 1

test_LINEFunction · 0.76