-
Notifications
You must be signed in to change notification settings - Fork 20
Linux Install Guide
- About Lexos
- Installing Python and Anaconda
- 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 3.8 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 v3.8 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: https://www.anaconda.com/download/. Locate the Linux symbol on the screen (the penguin); click on this Linux link to get to Anaconda For Linux Installer.
- Download the Python 3.8 version 64-Bit (x86) Installer by clicking on the green Download button.
- After locating the install script (e.g., in
Downloads/
by typingcd Downloads
in a terminal), run the (bash) shell installer by typing the following into your terminal:
bash Anaconda3-5.2.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 ensuring that you type in yes
when the terminal prompts you to install location to PATH in your /home/user/.bashrc
or simply follow the install instructions at https://docs.continuum.io/anaconda/install/linux. Close the terminal when you are done.
You should now verify that we have installed it correctly. To do this, follow the instructions below:
- Open an entirely new terminal window. This is important to ensure that your
$PATH
includes Anaconda. - Type
echo $PATH
and hit theEnter
key.
You should see a response that lists a number of file paths to various folders and executables in yout system. If you do not
see anaconda3/bin/python
somewhere in this list (likely at the beginning), then you did not 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 ~/anaconda3
, replacing anaconda3-5.2.0
with the
name of the Anaconda directory, if it is different. Hit the Enter
key.
Note: If any odd errors occur ensure your terminal is displaying something like
user@devicename
as your location, otherwise exit and open a new terminal.
To download Lexos, enter https://github.com/WheatonCS/Lexos in your browser's address bar. This will take you to the current version of Lexos:
Under the clone or download, download the zip file.
Once the Lexos zip archive has downloaded, right-click on the zip icon (in your Downloads), and select Extract or Open With > Archive Manager. Choose where you would like to install Lexos and click Extract. 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 user@devicename
. 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 like user@devicename: ~/Desktop/Lexos
.
Type pip install -r requirements.txt
and hit the Enter
key. This is a one time requirement to update the additional packages needed to run Lexos. When the update is completed you should see a message on your terminal window.
Note: The Lexos Bootstrap Consensus Tree tool is still in Beta. If run encounter an error installing biopython
or scikit-bio
, download the version of Lexos without this tool and try again.
Now navigate to the frontend
folder by typing cd Desktop/Lexos/lexos/frontend
and hit the Enter
key. Type npm install
and hit Enter
key. If you do not have npm
installed follow the instructions here (you may need to restart your computer after installation). This will install the final requirement to run Lexos.
Type python run.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:
Running on http://127.0.0.1:5000/ (Press CTRL+C to quit)
Restarting with stat
Debugger is active!
Debugger PIN: 236-087-009
Important: Keep the python run.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 run.py
.
Last edited: February 14, 2021 by Caleb Braddick
[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 August 2017, Anaconda includes 720+ 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