- Prof. Dancy's Site - Course Site -
Phase 1 Page, Final Phase Page
Objectivs & Overview
Project Deliverables
Project Point Breakdown
Teams of three students
Teams will be assigned by Prof. Dancy
Due-Dates:
- (Team info on Moodle): 30-Oct
- Phase 1: 09-Nov (10:00pm)
- Phase 1 presentations on 09-Nov (in class)
- Phase 2: 16-Nov (10:00pm)
- Phase 2 presentations on 16-Nov (in class)
- Final Phase: 06-Dec (10:00pm)
- Final presentations on 04-Dec (in Final Exam slot)
You're group is an elite group of developers that have been contracted by the Chicago Information Sciences Department. You've been asked by the Police Chief to develop a new police patroll dispatch system that his officers can use to fight crime in the most efficient way possible.
The Chief made this back of the napkin drawing to help you think about what he envisions as the final system (the Decision Engine)
To help with this, he's given you a dataset of previous crimes so that you can decide how you'll handle those new data that you'll be reading in.
Get to know your team. Teams will consist of three (or four) people & I will require that everyone speaks equally during the presentations and can explain any part of the work (within reason).
The team will work together to decide on a particular way to approach the above problem. It's up to you to communicate effectively so that you can work well as a team
I will work with teams to check on the status and get estimates of time for the completion of the project. While I will be available to try to make sure you don’t go off into a barren desert, and can help point you to resources if you wish to use a method that we have not gone over, the point of this Final project is to give you a bit of freedom to explore things, while still using some of the things we've learned in 204.
The chief loves what you've done, but needs some help with decision-making
Now that you have a way to lookup the priorities of locations and crimes for any dispatch coming in, we can now start to think about making decisions.
You need to make your decide_next_patrol
method should return where the next patrol should go:
string
to be entered that represents a 911 dispatch the format will come in as follows:
"ID, Case, Number, Date, Block, IUCR, Primary, Type, Description, Location Description, Arrest, Domestic, Beat, District, Ward, Community, Area, FBI Code, X Coordinate, Y Coordinate, Updated On, Latitude, Longitude"
← stringtuple
of 4 latitude-longitude tuples
that effectively give us four corners of an area to patrol.
((41.8763889,87.6216667), (41.6944444,87.6216667), (41.6944444,87.6205556), (41.8763889,87.6205556))
But how should you make these decisions?
Create an attribute for your main ChicagoCrimeFun
class called dispatch_queue
that will be used to decide where to send patrols when you have had 911 dispatch calls.
dispatch_queue
should be a MinHeap
that holds:
key
value
As with your AVL Tree, you should be creating a separate MinHeap
class.
You should use the following methods to add a dispatch to your MinHeap
(You must fill in the body of the metod):
def add_dispatch(self, dispatch_string):
'''
Method to add a dispatch to our dispatch_queue
Parameters:
dispatch_string: [string] A string that represents a recent 911 dispatch call request that is reported to the police
'''
def decide_next_patrol(self, new_request=None):
'''
Used to decide next place to send patrol
Parameters:
new_request: [string][optional] A string that represents a 911 dispatch call that is reported to the police
Returns:
[tuple] A tuple of length 4 that represents the 4 points of an area to patrol.
'''
pass
If your dispatch_queue
is not empty, you should be extract
ing from it to decide where to send the next patrol (and returning the tuple
to represent the area that the patrol should be covering.)
Thus, your decide_next_patrol
method should use the dispatch_queue
to find & return the next area to patrol if it isn't empty.
Your code should also be able to handle a dispatch with attributes you've never seen before. For example, if the request includes a representation of location that you've never seen before (and thus isn't in your AVL tree), you should pick some way to handle that request.
How should we handle a decide_next_patrol
call if our dispatch_queue
is empty?
So what about calls to our decide_next_patrol when our new_request is None
and our dispatch_queue
is empty?
To handle this scenario, I want you to create a sorted list from your AVL Trees using Heap Sort.
Your sorted list should be assigned to an attribute called crime_priority_list
Within your sorted list, each item should have a payload
that is made up of a key
and a value
key
should be the overall priorityvalue
should be a representation of location that would allow you to return "A tuple of length 4 that represents the 4 points of an area to patrol"
As with Phase 1, you will need to create a visualization for Phase 2.
Here you need to create a visualization that represents your MinHeap
.
You are welcome to use the same tools that you used previously, or to try something new!
To be clearer about what I mean here, I want to see some visualization that is a direct representation of your Heap. If you want more clarity or to see if something you create will get the full credit, ask!
Now is the time to expand your AVL visualization! Revisit your preivous choice of visualization
I want you to expand/modify your original AVL visualization in some way. You should explain what you did and why in your README.md (one of the Phase 2 deliverables)
Each team will be required to give a ~6
minute presentation on their implementations and the visualizations that they've created for Phase 2. You should be sure your presentation works on the classroom computer sometime before your presentation date or you must bring your own laptop, and make sure you know how to project your display on your external monitor port.
These presentations should give a good background on your design choices and the reasons for those choices. It will also be your chance to quickly discuss issues you have had or did have w/ the project.
More specifically, your presentation must provide answers to the following:
As with phase 1, your group should create a README that explains your project implementation up to Phase 2 (see more information below in the deliverables section)
As with phase 1, each person in your team will be required to give an end-of-phase reflection.
You should think of this like an additional journal, but specifically for the project.
This will be the time to reflect on:
ChicagoCrimeFun
class file, which should be named ChicagoCrime.py
Include your visualizations in the form of image files (.gif
, .jpg
, .png
, etc.)
In your submission, include a readme.md file named readme__GROUPNAME.md
that provides a brief statement of your project.
This is your opportunity to complete specific tasks, but (largely) using your own design decisions and implementation decisions.
The visualizations are your opportunity to think creatively and to think about ways to visualize data structures so that they are useful (and hopefully cool!)
By using those data, you also get a first chance at making something else that kind of looks like the start of an AI system
Graded item | Number of points |
---|---|
All methods included and work according to instructions | 15 pts |
dispatch_queue works as it should (including being a MinHeap) |
15 pts |
dispatch_queue visualization |
10 pts |
AVL tree visualizations expansion/modification (and expansion/modification explanation) | 5 pts |
Readme.md | 5 pts |
Presentation | 10 pts |
Reflection (individual) | 5 pts |
Creativity in visualization, implementation, etc. | 10 pts |
Graded item | Number of points |
---|---|
Previous phase solution overview | 1 pts |
Your solution to the problem posed during this phase | 2 pts |
Display of Visualizations created for this phase and raionale | 2 pts |
Discussion of current issues in project | 2 pts |
Discussion of things learned by each group member up to that point | 2 pts |
Group presentation time roughly evenly distributed | 1 pt |
Date | Milestone |
---|---|
28-Oct | Project assigned |
30-Oct, 10:00pm | Group Info Sheet due |
09-Nov (in-class) | Phase 1 Presentations, Phase 2 assigned |
09-Nov 10:00pm | Phase 1 Deliverables Due |
16-Nov (in-class) | Phase 2 Presentations |
16-Nov 10:00pm | Phase 2 Deliverables Due |
04-Dec | Final Phase Presentation |
06-Dec 10:00pm | Final Phase Deliverables Due |