Skip to main content

Matthew - Capstone Blog Post 1


First I would like to discuss our goals and long-term plans. We want to create an artificial intelligence that learns how to play first-person shooters without access to any game state data other than what can be gained through the audio and visual buffers. In other words, the AI will only have access to the information that a human player would. If we are successful with these constraints, then I could see our work leading to AI that can play any game, or even AI-driven robots that can play games using mechanical hands and eyes to operate normal peripherals and interfaces.

We are currently in the research and planning phase of the project. This means that our job right now is to decide exactly what tools and technologies we will use and how they will interact with one another. By the end of the semester, which will arrive sometime this December, we will need to be ready for phase two, which is the development, training, and testing phase. Yes, that is all three at once. However, if phase one goes as it should we will hopefully not be too overwhelmed. Having to go back and research during the next semester might be disastrous depending on the circumstances.

In order to protect ourselves from our own project, we aim to design a modular system. By this I mean that the AI will have "central executive" or core platform for general learning and decision-making which will take input from other, more specialized submodules. For example, we may decide to use a scene segmentation submodule. By taking this approach we can control the scope of our project by adding or cutting features as needed. Our worst case scenario would likely involve converting a failed project into a paper, such a literature review or postmortem depending on how we are advised.

How phase two goes depends substantially on what we do now. I am aware of two general approaches that are available to us at this stage. One of them, the literature review, involves investigating how other researchers have tried to solve the same problem or similar ones. The other, a technology assessment, consists of selecting a specific tool or technique and then determining how we might use it. The former can be difficult because there might be a lack of extant work, or their might be an unmanageable excess. It has the advantage of helping us avoid reinventing the wheel or falling into known pitfalls, though. To contrast: the latter might lead to innovative solutions, but it might also bring unforeseeable risks and challenges.

So far, Rei has pursued the route of technology assessment. Hopefully I can complement their excellent work with a detailed literature review. That will have to wait, however, because I am simply not there yet. I have collected a small body of relevant literature to look into. One of the documents I have is about an AI that learned to play Quake through imitation learning. The researchers' goal was to ensure that their AI played in a way that resembled how a human would, with natural movement and strategic planning. I also intend to read the ViZDoom papers, which should offer a variety of approaches to the problem of making an AI play Doom competitively. Beyond those papers, I have several others that address less holistic problems, such as moving target search. Overall, I think that the extant literature will prove manageable; there is an excess relating to technologies that might prove useful, alongside a comfortable amount relating to our particular problem.

Our biggest challenge, by far, will be learning as much as possible in a short amount of time about a topic that is not especially safe. We will have to contend with our own inexperience and lack of knowledge in the face of one of the bleeding edges of computer science.

Comments

Post a Comment

Popular posts from this blog

Matthew - Capstone Blog Post 4

Finally, our CSI-480 (Advanced Topics: AI) course material is catching up to where we need to be. We are covering perceptrons and sigmoid neurons in the lectures, and we are also using TensorFlow to solve some very simple introductory problems (via tutorials). To supplement this I have been reading Neural Networks and Deep Learning by Michael Nielsen, a textbook available for free on the internet, which dives into neural networks right from the first chapter. Additionally, I have been finding 3Blue1Brown's multi-part video series about deep learning to be extremely helpful for visualizing some of the more advanced concepts. Even if I do not fully understand the calculus and linear algebra involved, at the very least I have a better idea of what goes on inside of neural networks. For example: I know what loss and gradient descentalgorithmsdo, essentially, and I also understand how the latter helps find a local minimum for the former, but I do not necessarily feel confident in my …

Matthew - Blog Post 9

After our last meeting, Professor Auerbach asked us to shift our focus towards building and training our model. So that's what we've been working on lately. The results so far have been interesting and problematic.

The first step was to define a minimal working model and a loading system to feed it our labelled data-set. I wrote a Sequence subclass, which is essentially a kind of generator designed for use with the fit_generator method. With fit_generator and a sequence, we're able to train and test the model with just a couple of one-liners:

model.fit_generator(sequence)
model.evaluate_generator(sequence)

The sequence subclass also has a few other tricks up its proverbial sleeve. For one, it reduces the dimensionality of the frame buffer data from 135×240×3 to 135×240×1 by converting it to gray-scale. This reduces the number of features from 97,200 to 32,400. For two, it does the same with the labels, combining and dropping 26 action types into just 9 atomic classes. This a…

Matthew - Blog Post 7

Since January, we've been working hard to not only finish writing the Replay Parser and Frame Collector but also totally synchronize them. I'm pleased to report our success. This is an amazing milestone for us because it means that we've surmounted one of our most troubling obstacles.


I have also made sure to keep our documentation up to date. So, if you like, you can follow along with this blog post by replicating its results.
The Frame Collector uses timed input sequences to start each replay associated with the currently running game version. Then, after waiting a set amount of time for playback to begin, it starts grabbing 1/4-scale frames at a rate of 10 frames per second. The Frame Collector takes these down-scaled frames, which are NumPy arrays, and rapidly pickles and dumps them into the file system. Here's a screenshot of the Frame Collector in action:

If you look at the image above, you'll see that each pickle (the .np files) is simply assigned …