-
Notifications
You must be signed in to change notification settings - Fork 20
Linux Install Guide
- About Lexos
- Installing Python and Anaconda
- Installing Additional Packages
- Downloading and Extracting Lexos
- Starting and Launching Lexos
- Quitting Lexos
Lexos is an integrated workflow of tools to facilitate computational text analysis, presented in a web-based interface. Lexos is written primarily in Python 2.7.11 using the Flask microframework, based on Werkzeug and Jinja 2. A heavy dose of Javascript and CSS is included on the front-end. We increasingly incorporate the wiz from D3.js in our visualizations and the power in the scikit-learn modules for text and statistical processing.
If you do not already have Python v2.7 installed on your computer, we recommend installing it through the free Anaconda distribution.[1] If you already have Python, Anaconda will run alongside your current installation.
- Visit the Anaconda downloads page on the web: http://continuum.io/downloads. Locate the Jump to: on the screen; click on the Linux link.
- Download the Linux 64-bit Graphical Installer by clicking on the blue button.
- Double-click the installer application icon (it will be called something like
Anaconda2-4.1.1-Linux-x86_64.sh
) and follow the instructions on the screen. - After locating the install script (e.g., in
Downloads/
, run the (bash) shell installer:
bash Anaconda-4.0.0-Linux-x86_64.sh
Note: A newer version of Anaconda may have a new version number; check your exact filename.
Follow the instructions on the screen, and, when the process is complete, select Finish to finish the installation of Anaconda.
You should now verify that we have installed it correctly. To do this, follow the instructions below:
- Open a terminal window. This is important to ensure that your
$PATH
includes Anaconda. - Type
python -V
and hit theEnter
key.
You should see a response that looks like: Python 2.7.12 :: Anaconda 4.1.1 (64-bit)
. If you do not
see :: Anaconda 4.1.1
then you did open a new terminal window or you did not update your PATH
variable during the Anaconda installation. We recommend that you uninstall Anaconda and try to install it again, following the
instructions above. To uninstall Anaconda, type rm -rf ~/anaconda2
, replacing anaconda2
with the
name of the Anaconda directory, if it is different. Hit the Enter
key.
You must now install three additional Python packages needed to run Lexos.
- Begin my making sure that your package installer (pip) is up to date. Type
pip install -U pip
and hit theEnter
key. Your terminal window will display some information showing you the update process. Once that is completed, you can now use 'pip' (python package installer) in the next step. - Type the following three commands, hitting the
Enter
key after each one. The installation process for each may take some time.
pip install gensim
pip install chardet
pip install natsort
When the last installation is finished, you are ready to download Lexos.
To download Lexos, enter https://github.com/WheatonCS/Lexos/archive/3.1.zip in your browser's address bar.
Once the Lexos zip archive has downloaded, right-click on the zip icon, and select Open With > Archive Utility. Choose where you would like to install Lexos. If you wish, you may change the name of the extracted folder from Lexos-master
to Lexos
. In the instructions below, we will assume that you did this and that you extracted the Lexos
folder to the Desktop.
Important: Close your current terminal window and open a new one.
In most cases, the terminal window will open in your computer's user account directory. It will show your location by displaying something like /users/YOUR_NAME
. If the command prompt says something else, you may need to navigate to this folder.
Now navigate to the Lexos
folder by typing cd Desktop/Lexos
and hit the Enter
key. If you encounter an error, make sure that you are starting in your user account folder, that the Lexos folder is on the Desktop, and that it is called Lexos
. The terminal should now display something liken /users/YOUR_NAME/Desktop
.
Type python lexos.py
and hit the Enter
key. This will start Lexos. It may take a minute to see a response the first time you run the command because Python has to reconfigure some of the project files for your computer. But shortly after you should see the following:
Restarting with stat
Debugger is active!
Debugger pin code: 236-087-009
Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
Important: Keep the python lexos.py
command running while you use Lexos. You may minimize the terminal window, but do not close it.
Once you see the message above, you are ready to launch Lexos. Go to a web browser and enter localhost:5000
in the address bar. We recommend using either Firefox or Chrome (other browsers are not supported and may not work with Lexos). You will soon see the Lexos upload page. For information about using Lexos, click the "Gear" icon at the top right of the screen.
Note: Because your computer is acting as both the web server and the user of Lexos, you may need to hit the Reset button in the top right corner of the Upload page to make sure files from any previous sessions are purged.
To quit Lexos simply close your browser window and close the terminal window running python lexos.py
.
Last edited: August 20, 2016
[1] Anaconda is a free distribution of the Python programming language for large-scale data processing, predictive analytics, and scientific computing, that aims to simplify package management and deployment. As of June 2016, Anaconda includes 820+ of the most popular Python packages, including most of the packages needed for Lexos.
- User's Guide
- Developer's Guide
- Lexos Bootcamp
- Git Basic
- Git on Pycharm
- Python Tutorial
- Python Coding Style Guide
- Back End Developer's Guide
- The Lexos 4 Frontend
- Javascript Library Maintenance
- In the Margins Content Guide
- Lexos Server Deployment Guide
- How to Install scikit-bio on Windows
- Ajax and jQuery
- Wiki Archiving Guide
- Unit Testing Guide
- Repo Administration Guide
- Proposals