Recursive Python Algorithm to Model Among Us смотреть онлайн
The final installment in the game theory of Among Us series. See code below
0:00 - Explanation of recursive algorithms
3:04 - Problems with simple decision tree models
3:54 - Model with 'simulated rounds'
5:38 - Problems with the final model
6:06 - Features of the final model
7:29 - Explanation of code
11:45 - Skip on 7?
13:09 - Clutch scenarios
14:32 - All minimum certainty results
15:32 - All random voting results
Code (note that less than and greater than symbols are not allowed by youtube so theyre replaced by lessthan and greaterthan respectively):
import numpy as np
def ev(amount_of_impostors, amount_of_crew, certainty=None, main=False):
"""Recursive function that returns expected value of voting someone off"""
impostors, crew, winrate = amount_of_impostors, amount_of_crew, certainty
kills = [-1, 0, 0, 1]
# [0, 1, 1, 2] with 1 impostor
# [1, 2, 2, 3] with 2 impostors
if (crew lessthan= 2 * impostors and not main) or crew == 1:
# We lost! (impostors can kill remaining crew)
return -1
if impostors lessthan= 0:
# We won! (no remaining impostors)
return 1
if certainty is None:
# If no certainty is given, we are guessing
winrate = impostors / (impostors + crew)
if main:
# If in the main branch, don't factor in kills, just calculate EVs
ev_correct = ev(impostors - 1, crew, certainty)
ev_wrong = ev(impostors, crew - 1, certainty)
return ev_correct * winrate + ev_wrong * (1 - winrate)
else:
# If we're not in the main branch, create a new branch for each possible kill
evs = []
for kill in kills:
ev_correct = ev(impostors - 1, crew - kill - impostors, certainty)
ev_wrong = ev(impostors, crew - 1 - kill - impostors, certainty)
evs.append(ev_correct * winrate + ev_wrong * (1 - winrate))
return np.average(evs)
def minimum_certainty(amount_of_impostors, amount_of_crew, accuracy):
"""Return minimum certainty to get EV = 0"""
impostors, crew = amount_of_impostors, amount_of_crew
certainty, step = 0, 1 / accuracy
for i in range(accuracy):
value = ev(impostors, crew, certainty, main=True)
if value greaterthan= 0:
return certainty
else:
certainty += step
return "Greater than 1"
Что делает видео по-настоящему запоминающимся? Наверное, та самая атмосфера, которая заставляет забыть о времени. Когда вы заходите на RUVIDEO, чтобы посмотреть онлайн «Recursive Python Algorithm to Model Among Us» бесплатно и без регистрации, вы рассчитываете на нечто большее, чем просто загрузку плеера. И мы это понимаем. Контент такого уровня заслуживает того, чтобы его смотрели в HD 1080, без дрожания картинки и бесконечного буферизации.
Честно говоря, Rutube сегодня — это кладезь уникальных находок, которые часто теряются в общем шуме. Мы же вытаскиваем на поверхность самое интересное. Будь то динамичный экшн, глубокий разбор темы от любимого автора или просто уютное видео для настроения — всё это доступно здесь бесплатно и без лишних формальностей. Никаких «заполните анкету, чтобы продолжить». Только вы, ваш экран и качественный поток.
Если вас зацепило это видео, не забудьте взглянуть на похожие материалы в блоке справа. Мы откалибровали наши алгоритмы так, чтобы они подбирали контент не просто «по тегам», а по настроению и смыслу. Ведь в конечном итоге, онлайн-кинотеатр — это не склад файлов, а место, где каждый вечер можно найти свою историю. Приятного вам отдыха на RUVIDEO!
Видео взято из открытых источников Rutube. Если вы правообладатель, обратитесь к первоисточнику.