Skip to Main Content
Машинное обучение с PyTorch и Scikit-Learn
book

Машинное обучение с PyTorch и Scikit-Learn

by Sebastian Raschka, Yuxi (Hayden) Liu, Vahid Mirjalili
May 2024
Beginner to intermediate content levelBeginner to intermediate
688 pages
26h
Russian
Foliant
Content preview from Машинное обучение с PyTorch и Scikit-Learn
666 Глава 19
self.state2grid_dict = {s: (s // num_cols, s % num_cols)
for s in range(nS)}
# Состояние: кл ад
gold_cell = (num_rows // 2, num_cols - 2)
# Состояние: ло вушки
trap_cells = [((gold_cell[0] + 1), gold_cell[1]),
(gold_cell[0], gold_cell[1] - 1),
((gold_cell[0] - 1), gold_cell[1])]
gold_state = self.grid2state_dict[gold_cell]
trap_states = [self.grid2state_dict[(r, c)]
for (r, c) in trap_cells]
self.terminal_states = [gold_state] + trap_states
print(self.terminal_states)
# Построение ве роятности перех ода
P = defaultdict(dict)
for s in range(nS):
row, col = self.state2grid_dict[s]
P[s] = defaultdict(list) ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

CompTIA Network+ -- Vorbereitung auf die Prüfung N10-009

CompTIA Network+ -- Vorbereitung auf die Prüfung N10-009

Markus Kammermann

Publisher Resources

ISBN: 9786011100342