Python

Installing Python Modules

How to install local python modules in the Linux Labs

Lab 1 Introduction to Linux

Aims The aim of this lab is to introduce some basic Linux commands and tools The terminal and why it is important basic linux commands ls,pwd,mkdir,cd,rm,man,history. The environment and how to set it up Getting Started The first thing we need to do is to get a terminal open. On Linux this is usually done by pressing the ctrl-alt-t keys. I actually have a default terminal open on login as I use it so much.

Lab 1 Introduction to Linux

Aims The aim of this lab is to introduce some basic Linux commands and tools The terminal and why it is important basic linux commands ls,pwd,mkdir,cd,rm,man,history. The environment and how to set it up Getting Started The first thing we need to do is to get a terminal open. On Linux this is usually done by pressing the ctrl-alt-t keys. I actually have a default terminal open on login as I use it so much.

Lab 1 Python Setup and Install

Aims The aim of this lab is to help setup and install python and various other tools Using PyEnv for installation of python versions Using Pip to install packages Setup VSCode to edit and run python files Why do I need PyEnv? At present the version of python installed in our linux labs are

Install and Setup of PyEnv

PyEnv can be installed by downloading from here https://github.com/pyenv/pyenv or if using a mac use brew install pyenv If downloading from github do the following git clone https://github.com/pyenv/pyenv.git ~/.pyenv cd ~/.pyenv && src/configure && make -C src If using homebrew this will be installed into your homebrew path.

Lab 2 More Linux

Aims The aim of this lab is to introduce more basic Linux commands and tools Essential Linux Directories Most linux environments have a similar directory structure. The following is a list of the most important directories and their purpose.

Lab 2 More Linux

Aims The aim of this lab is to introduce more basic Linux commands and tools Essential Linux Directories Most linux environments have a similar directory structure. The following is a list of the most important directories and their purpose.

Lab 2 Functions and Modules

Aims The aim of this lab is to setup a simple python project using the Turtle module and experiment with writing code and functions. By the end of the Lab we should be able to

MayaPY not working

When running the following code in a mayapy session import maya.standalone maya.standalone.initialize(name='python') The interpreter never returns for the next line of code. TL;DR was an issue with my userSetup.py where I use cmds.commandPort I guess before maya is ready. I’m guessing this is actually a bug where standalone python reads this before it is ready.

Lab 3 PyEnv

Aims The aim of this lab is to help setup and install python and various other tools Using PyEnv for installation of python versions Using Pip to install packages Setup VSCode to edit and run python files Why do I need PyEnv? At present the version of python installed in our linux labs are as follows