Visualizing Machine-Learned Programs – CS 550 Term Project
Background
The purpose of this project is to visually explain a machine learning classifier’s logic to an end user. Additionally, the user must be able to explain back to the classifier when its logic is faulty and how it should be fixed.
Implementation
This project was designed in C++ using OpenGL. I used GLUT primitives such as glutSolidCube() to create the basic components, then reshaped and arranged them using OpenGL transformations. In order to create the translucent regions, I needed to enable lighting and shading. Blending was then used to create the illusion that each word’s bar is inside one or more of the translucent boxes. The text was created using glutStrokeCharater() calls; regular bitmap fonts were not an option because I wanted to rotate the text beneath the word boxes. The resulting words suffered from severe aliasing problems, so I used the OpenGL accumulation buffer to enable 8x anti-aliasing.
Usage
While this project is not actually hooked up to a classifier, the word importance can still be manipulated by dragging the bars up or down into the desired regions. There are also controls in a secondary window for rotating the view or panning right and left.
Room for Improvement
Ideally, this explanation would be interacting with a classifier; changes made to word importance would then be instantly viewable in the application when it re-classifies based upon the user’s adjustments. I would also have liked to make it possible to zoom in and out so that the user can fit exactly as many words on-screen as she would like. Finally, the blending of the word boxes with the translucent boxes isn’t entirely right–the word boxes should slightly change color depending on which region they are.
Downloads
Source code (for Visual Studio 2008)
Windows Binary (Requires OpenGL, GLUT and GLUI libraries)









