代写辅导接单-CPSC 383: --Assignment 1

欢迎使用51辅导,51作业君孵化低价透明的学长辅导平台,服务保持优质,平均费用压低50%以上! 51fudao.top

CPSC 383: Explorations in Artificial Intelligence and

Machine Learning

Assignment 1: Symbolic AI, Agents, Search, Pathfinding, A*

Weight: 15%

Collaboration

Discussing the assignment requirements with others is a reasonable thing to do, and an

excellent way to learn. However, the work you hand-in must ultimately be your work. This is

essential for you to benefit from the learning experience, and for the instructors and TAs to

grade you fairly. Handing in work that is not your original work, but is represented as such, is

plagiarism and academic misconduct. Penalties for academic misconduct are outlined in the

university calendar.

Here are some tips to avoid plagiarism in your programming assignments.

1. Cite all sources of code that you hand-in that are not your original work. You can put the citation into

comments in your program. For example, if you find and use code found on a web site, include a comment

that says, for example:

# the following code is from

https://www.quackit.com/python/tutorial/python_hello_world.cfm.

Use the complete URL so that the marker can check the source.

2. Citing sources avoids accusations of plagiarism and penalties for academic misconduct. However, you may still

get a low grade if you submit code that is not primarily developed by yourself. Cited material should never

be used to complete core assignment specifications. You can and should verify and code you are concerned

with your instructor/TA before submission.

3. Discuss and share ideas with other programmers as much as you like, but make sure that when you write your

code that it is your own. A good rule of thumb is to wait 20 minutes after talking with somebody before

writing your code. If you exchange code with another student, write code while discussing it with a fellow

student, or copy code from another person’s screen, then this code is not yours.

4. Collaborative coding is strictly prohibited. Your assignment submission must be strictly your code. Discussing

anything beyond assignment requirements and ideas is a strictly forbidden form of collaboration. This includes

sharing code, discussing code itself, or modelling code after another student's algorithm. You can not use

(even with citation) another student’s code.

5. Making your code available, even passively, for others to copy, or potentially copy, is also plagiarism.

6. We will be looking for plagiarism in all code submissions, possibly using automated software designed for the

task. For example, see Measures of Software Similarity (MOSS - https://theory.stanford.edu/~aiken/moss/).

7. Remember, if you are having trouble with an assignment, it is always better to go to your TA and/or instructor

to get help than it is to plagiarize. The most common penalty is an F on a plagiarized assignment.

8. For assignments limited use of generative AI in writing assistance is acceptable. For example, grammar

suggestion, or code suggestion tools for programming. Programming or text that is largely generative AI

produced is not allowed. Learners are ultimately accountable for the work they submit. Use of AI tools must

be documented in an appendix for the assignment. The documentation should include what tool(s) were used,

how they were used, and how the results from the AI were incorporated into the submitted work. Failure to

cite the use of AI generated content in an assignment will be considered a breach of academic integrity and

subject to Academic Misconduct procedures.

Late Penalty

For late individual assignments, those submitted within 24 hours of the initial deadline will

receive 10% off, and within 48 hours will receive 20% off. After 48 hours, no late assignments

will be accepted.

Goal

Within the provided AEGIS system modify the provided Python agent code to allow the agent

to path-find using A* to the SURVIVOR grid location. The solution must be written by you the

student and not use existing libraries.

Technology

AEGIS, Python 3

Submission Instructions

You must submit your assignment electronically using D2L. Use the Assignment 1 dropbox in

D2L for a final codebase electronic submission. In D2L, you can submit multiple times over the

top of a previous submission. Do not wait until the last minute to attempt to submit. You are

responsible if you attempt this, and time runs out. Your assignment must be completed in

Python 3.

Description

What is AEGIS?

The Goobs have sent an elite space force to occupy AEGIS, the galaxy's central hub dedicated to

saving lives across the galaxy. This futuristic space station floats in a serene nebula, and it's the

last beacon of hope in the vast and dangerous expanse of space. Equipped with powerful

scanners and teleportation gates, AEGIS connects distant worlds and provides a lifeline in the

galaxy's most perilous regions. From here, they embark on their journeys, navigating the

galaxy's dangers to rescue those in distress and tackle the most formidable dangers.

AEGIS is a simulated agent disaster rescue scenario environment written in Python 3 with an

optional Electron-based GUI. AEGIS consists of a simulation controller that manages all

communication with agents, executes the simulation, and maintains the current state of the

world. It updates the world as events happen. If the optional GUI is used, the GUI displays real- time updates of the world’s state during the simulation. Additionally, the GUI allows users to

create their own worlds.

Full documentation is available here and students are expected to read this themselves to

complete the assignment: https://cspages.ucalgary.ca/~jwhudson/CPSC383F24/aegis/docs/

Tutorials will also introduce students to the AEGIS system.

The AEGIS simulation is turn-based. When agents first CONNECT they are given a simplified

rectangular grid view of the world which will include if a grid is safe to move on, or if the grid is

FIRE/KILLER which will immediately kill an agent moving on top of it. This initial view of the

world will also indicate where the ONE SURVIVOR is located in the grid. A configuration option

Enable_Move_Cost for AEGIS will allow for the complete grid energy move costs to be

communicated on connection success, or if they won’t which will require the agent to reveal

this information through MOVE_RESULT updates.

A simulation consists of multiple rounds, with each round being a single time step in the

simulated world. During each round each agent is given one second to decide what action to

take. AEGIS processes each agent one by one and waits for their command. The last action

command received from an agent is the one that will be executed for that round. Agents have

energy that is expended each time they use commands. If their energy expiries the agent

becomes non-functional.

For assignment 1 your ONE AGENT need to be concerned with the commands of MOVE and

SAVE_SURV (save survivor).

https://cspages.ucalgary.ca/~jwhudson/CPSC383F24/aegis/docs/agent_commands/move/

MOVE allows an agent on its turn to move in 1 of the 9 neighboring grid locations, or CENTER to

not move.

https://cspages.ucalgary.ca/~jwhudson/CPSC383F24/aegis/docs/aegis_commands/move- result/

The result of a MOVE action is a MOVE_RESULT that informs an agent of its remaining energy

levels and information about the surrounding grid locations around the agent’s new location.

https://cspages.ucalgary.ca/~jwhudson/CPSC383F24/aegis/docs/agent_commands/save-surv/

Once the agent moves onto the grid location containing the survivor the SAVE_SURV command

is used to end the simulation.

Assignment Challenge

Your agent in AEGIS will begin on a grid location that does not contain the SURVIVOR. It will be

your job to move your agent each round until it is at the survivor location and then use

SAVE_SURV to end the simulation. To accomplish this goal you will be using A*, a very common

path-finding algorithm. A*, as introduced in class, is a graph search algorithm that uses an

admissible heuristic to provide an optimal sequence of MOVE commands so that your agent

reaches the survivor as promptly as possible. You will be creating an A* solution for this

assignment that can solve three versions of the AEGIS path-finding problem.

1. In version 1, all move costs will be equal. Your agent will need to use A* to avoid instant- death KILLER/FIRE grids to navigate the survivor in the shortest path (fewest MOVE

commands) possible. Note, that sometimes the path will not be a straight-forward and

require some maze-solving.

a. “Enable_Move_Cost” : true

2. In version 2, AEGIS will provide move costs of varying value. It is your job to find the

path to the survivor that minimizes the energy costs of the agent. This path may be

longer than the shortest path that ignores move costs.

a. “Enable_Move_Cost” : true

3. In version 3, AEGIS will only provide move costs as the result of MOVE actions (not at

the start of the simulation). Your agent will have to solve the path-finding problem

without knowing move costs at the beginning. In other words, you will have to assume

early move costs, and as your agent completes move actions your agent will have to re- assess the best path to the survivor. Note, this could mean pathfinding in one direction

before finding that there was a previously unrevealed wall of energy exhausting grid

locations that your agent was unaware of.

a. “Enable_Move_Cost” : false

Assignment 1 config modifiers are discussed in

https://cspages.ucalgary.ca/~jwhudson/CPSC383F24/aegis/docs/a1_config/

Solution

A* star is a very well-known algorithm https://en.wikipedia.org/wiki/A*_search_algorithm . You

can find pseudo-code and explanations all over the internet. If you use such a resource

(including that Wikipedia link), you should reference it in your code submission.

Starter agent code has been provided for you that handles MOVE_RESULT to store world

information updates for you. You will need to modify the think() function in the agent to use

your A* path-finding. In think() you will need to solve A* for your World state to find a path

towards the one SURVIVOR grid location. Your grid data will not have survivor grid details after

the initial CONNECT has completed but will have a percent_chance variable that is non-zero to

tell you where the SURVIVOR is located.

Evaluation

The files provided for assignment include 2 example world files for each of the three versions.

For version 1 and 2 the AEGIS setting that turns on CONNECT success resulting in complete

move costs knowledge at the start, should be on (“Enable_Move_Cost”: true). For version 3

this option should be off

(“Enable_Move_Cost”: false).

You are free to make, and share in

discord, other example worlds you make using AEGIS to test your system.

For grading the instruction staff will have at least 5 world files for each of the versions that will

be used to assess students submitted code.

Additional Specification

• You must comment your code and provide citations for the source of algorithmic designs and

note any co-pilot like code suggestion usage.

• Put your name, date, course, semester, and tutorial into the comments of the

example_agent.py (and other) files modified or created by you to complete your agent.

• Do not rename or modify the provided common files. You can create new .py files used by

example_agent.py.

• You should not import ANY libraries to complete the A* algorithm. Using such could result in

grade of 0 for that portion of assignment.

• Do not change provided code without discussion with instructor. If there is a bug, or something

is broken, the instructor should be informed to fix this issue.

Grading

The total grade is out of 20.

Version 1

5 test maps (success if minimum path is achieved -> least move actions)

Version 2

5 test maps (success if minimum move cost path is achieved)

Version 3

5 test maps (success if minimum move cost path is achieved with challenge of having to re-plan

when move costs are revealed as agents MOVE)

Style/Commenting (out of 5)

Name/Date/Course/Semester/Tutorial, don’t change files, etc.

Submit the following using the Assignment 1 Dropbox in D2L

1. example_agent.py

a. Any other .py files created and used by example_agent.py

51作业君版权所有

51作业君

Email:51zuoyejun

@gmail.com

添加客服微信: Fudaojun0228