Coder Social home page Coder Social logo

tckb / awp Goto Github PK

View Code? Open in Web Editor NEW

This project forked from alfonsogonzalez/awp

0.0 1.0 0.0 37.31 MB

Astrodynamics with Python book, software, and videos. Spacecraft trajectory and attitude modeling and simulation

Python 77.97% TeX 21.40% Makefile 0.63%

awp's Introduction

AWP - Astrodynamics with Python

prof-pic cosmo-3d-launches groundtracks-earth-img

The GitHub repository corresponding to the YouTube channel (https://www.youtube.com/AlfonsoGonzalezSpaceEngineering), which contains the following video series:

Dependencies

Installing Python dependencies

Python packages can be easily and conviniently installed using pip via the command line like so:

$ python3 -m pip install {package_name}

In the case of AWP, all Python dependencies can be installed in one command using the requirements.txt file as so:

$ python3 -m pip install -r requirements.txt

Setting the PYTHONPATH Environment Variable

In order to use this repository path independently (can run any script from any directory), one must set the PYTHONPATH environment variable to point to the python_tools directory of this repoistory:

  • PYTHONPATH: Absolute path to your python_tools directory
# Two examples of how to set the PYTHONPATH variable for Linux / MacOS

$ export PYTHONPATH=$PYTHONPATH:/home/alfonso/AWP/src/python_tools
# or
$ export PYTHONPATH=$PYTHONPATH:~/AWP/src/python_tools
rem Examples of how to set the PYTHONPATH variable for Windows

$ set PYTHONPATH=C:\Users\alfon\AWP\src\python_tools

For convenience, this command can be placed in a .bash_profile or .bashrc file and thus will be automatically set anytime a new terminal session is begun.

Running Example Usages

Once the dependencies are installed and PYTHONPATH is set, the example usage cases can be run (from the base path of this repository):

# ensure you are in the base path of this repository
$ pwd
/home/alfonso/AWP
# run the example usages
$ python3 example_usage/Spacecraft_hello_world.py
$ python3 example_usage/many_orbits.py
$ python3 example_usage/groundtracks.py

Running Unit Tests

Again, once dependencies are installed and PYTHONPATH is set, the unit tests can be run with the following command (from the base path of this repository):

# ensure you are in the base path of this repository
$ pwd
/home/alfonso/AWP
# run the unit tests using one of the following commands
$ pytest src/python_tools/unit_tests/ -vv
# or
$ python3 -m pytest src/python_tools/unit_tests/ -vv

The only difference between those two commands is that running pytest through the Python interpreter is that python will add your current directory to sys.path

awp's People

Contributors

alfonsogonzalez avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.