Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS236501 Introduction to AI Tutorial 6 AB Questions Tutorial 6 AB Questions.

Similar presentations


Presentation on theme: "CS236501 Introduction to AI Tutorial 6 AB Questions Tutorial 6 AB Questions."— Presentation transcript:

1 CS236501 Introduction to AI Tutorial 6 AB Questions Tutorial 6 AB Questions

2 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich2 שאלה 1 מתכנת התבלבל והחליף את הקריאה הרקורסיבית board-val = ab(v, d-1, max, alpha, beta) בקריאה board-val = minimax(v, d-1, max) תארו את כל ההשלכות של הטעות

3 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich3 αβ Procedure: MAX node if node-type = MAX { curr-max ← -infinity loop for v i є Succ(v) { board-val ← αβ(v i, d-1, min, α, β) curr-max ← max(board-val, curr-max) α ← max(curr-max, α) if (curr-max ≥ β) // Bigger than lowest min end loop } return curr-max }

4 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich4 Game Tree Example 12142113151410119202231425 MAX MIN

5 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich5 שאלה 2 מה יקרה אם נחליף באלגוריתם האלפא - ביתא את השורה alpha = max(curr-max, alpha) בשורה alpha = curr-max

6 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich6 שאלה 3 אם מינימקס לעומק D מחזיר ערך M, מובטחת לשחקן האפשרות להגיע ללוח עם ערך של לפחות M. נניח שמפאת חוסר זמן אנו רוצים לשמור את האסטרטגיה שמבטיחה לנו ערך זה. כלומר, ב -D צעדים הבאים השחקן לא יצטרך לבצע חיפוש, אלא יענה באופן מיידי בהסתמך על האסטרטגיה ששמר. מה השינויים שתערכו במינימקס כדי לשמור אסטרטגיה זו ואיך תשתמשו בה ?

7 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich7 שאלה 4 הוחלט לבנות תכנית שחמט חדשה שתנצח את קספרוב. מכיוון שקספארוב מסוגל ללמוד במהירות את הטכניקה של יריביו, הוחלט לבלבל אותו ע " י שינוי של האלגוריתם אלפא - ביתא. במקום להחזיר צעד אחד בעל ערך המינימקס המקסימלי MM, האלגוריתם מחזיר את כל הצעדים שערך המינימקס שלהם לפחות MM – epsilon. התכנית מגרילה צעד אחד מבין צעדים אלה. מהם השינויים הדרושים לאלגוריתם האלפא - ביתא ? פתרון פשוט הוא לקרוא לאלפא - ביתא מהבנים של שורש העץ, אולם אנו מעוניינים בפתרון שמאפשר יותר גיזום

8 CS236501 Introduction to AI Tutorial 6 Class Tournament Tutorial 6 Class Tournament

9 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich9 Tournament Details Several rounds with different game parameters and move time limit parameters In each round, every player will play against all other players –Even number of games –Half of the games white, half black Scores: 1 pt for victory, 0.5 pts for draw Tournament winner: maximal score, summarized over all rounds

10 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich10 Player Details The player should continue running during the whole game –This allows keeping some data structures in memory during the game –Player not allowed to use idle time (other player’s turn) for calculations

11 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich11 Technical Details The player gets its input from stdin, and outputs its move to stdout. An outline of our mechanism: > our_app1 | player1 … -color white | our_app2 & > our_app3 | player2 … -color black | our_app4 & our_app1 supplies the current board to stdin of player1 our_app2 reads the next board from stdout of player1 and checks whether –The board is a legal move –The move was done within the time limit –The board is final If the game can continue, our_app2 communicates the move to our_app3, and so on… (our_app4 communicates with our_app1)

12 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich12 Time Limits There is a time limit per move The time is counted in from the moment that a board was sent to stdin of a player, till a new legal board was received from stdout of the player We will take into account the delays of the operating system and our communication delays, and allow a (very) small overhead

13 27-Jun-15Intro. to AI – Tutorial 6 – By Nela Gurevich13 General Guidelines Cheating is not legal Everything else is


Download ppt "CS236501 Introduction to AI Tutorial 6 AB Questions Tutorial 6 AB Questions."

Similar presentations


Ads by Google