After 4 hours of unsuccessful attempts to set up tensorflow in Docker on Windows, I decided to – just for fun – try to run it in the shiny new Windows Subsystem for Linux on my Windows 10 Insider Preview Build 14332. What began with low expectations turned out to be very successful, so here are the steps: First enable the Windows Subsystem for Linux in the “Turn Windows features on or off” dialog: Then open the Ubuntu Bash and update the package index: You can now proceed to install pip for Python 2: Now install the CPU-enabled Linux x64 tensorflow package:: Tensorflow is now installed. With the following command, you can get the directory of the installed package: This should give something like “/usr/local/lib/python2.7/dist-packages/tensorflow”. Now let’s cd to the directory with the example implementation of a CNN for the MNIST dataset: And run the convolutional neural network: In the…
Category: Machine Learning
Learn and Predict the Gender of German Nouns
The German language is know to be relatively complicated and especially the gender causes lots of confusion. While English has only one article (the), three different articles are used in German: der (male) die (female) das (neuter) While rules to determine the gender of a noun exist, almost no German native speaker can name them. We can now solve this problem (determine the gender without memorizing the rules) using some simple machine learning with the Accord framework. Let’s quickly name the steps that will follow: find and extract a dataset of noun-gender associations split into training, test and validation dataset extract features into something the algorithm can use train a Naive Bayes test the model with the test dataset After quite a while of searching, I found this machine readable and CC-BY-SA 4.0 licensed XML file from Daniel Naber. In our Universal Windows App we can then load all nouns into…