mtgencode uses a few additional Python packages which you should be able to install with Pip, Python's package manager. They aren'y mission critical, but they provide better capitalization of names and text in human-readable output formats. If they aren't installed, mtgencode will silently fall back to less effective workarounds.
On Ubuntu, you should be able to install the necessary packages with:
```
sudo apt-get install python-pip
sudo pip install titlecase
sudo pip install nltk
```
nltk requires some additional data files to work, so you'll also have to do:
```
mkdir ~/nltk_data
cd ~/nltk_data
python -c "import nltk; nltk.download('punkt')"
cd -
```
You don't have to put the files in ~/nltk_data, that's just one of the places it will look automatically. If you try to run decode.py with nltk but without the additional files, the error message is pretty helpful.
mtgencode can also use numpy to speed up some of the long calculations required to generate the creativity statistics comparing similarity of generated and existing cards. You can install numpy with:
```
sudo apt-get install python-dev python-pip
sudo pip install numpy
```
This will launch an absolutely massive compilation process for all of the numpy C sources. Go get a cup of coffee, and if it fails consult google. You'll probably need to at least have GCC installed, I'm not sure what else.
Some additional packages will be needed for multithreading, but that doesn't work yet, so no worries.
That should create some files, among them a binary called word2vec. Add this to your path somehow, and you'll be able to invoke cbow.sh from within the data/ subdirectory to recompile the vector model (cbow.bin) from whatever text representation was last produced (cbow.txt).
MSE2 is a tool for creating and viewing custom magic cards:
http://magicseteditor.sourceforge.net/
Set files, with the extension .mse-set, can be produced by decode.py using the -mse option and then viewed in MSE2.
Unfortunately, getting MSE2 to run on Linux can be tricky. Both Wine 1.6 and 1.7 have been reported to work on Ubuntu; instructions for 1.7 can be found here:
https://www.winehq.org/download/ubuntu
To install MSE with Wine, download the standard Windows installer and open it with Wine. Everything should just work. You will need some additional card styles:
Open them in Font Viewer and click install; you might then have to clear the caches so MSE2 can see them:
```
sudo fc-cache -fv
```
If you're running a Linux distro other than Ubuntu, then a similar procedure will probably work. If you're on Windows, then it should work fine as is without messing around with Wine. You'll still need the additional styles.
I tried to build MSE2 from source on 64-bit Ubuntu. After hacking up some of the files, I did get a working binary, but I was unable to set up the data files it needs in such a way that I could actually open a set. If you manage to get this to work, please explain how, and I will be very grateful.