Git Product home page Git Product logo

mats-planningtool's Introduction

MATS-planningtool

Mission planning tool for the MATS satellite

OPT (Operational_Planning_Tool) requires at least Python 3.7.3 and these packages (newer versions might work):

	ephem = Version: = 3.7.6.0
	matplotlib = Version: = 3.1.1
	scipy = Version: = 1.2.1
	lxml = Version: >= 4.3.3
	astroquery, Version: >= 0.3.10, astropy
	skyfield, Version: = 1.13
	astropy, Version >= 4.0, astropy
	h5py, Version = 2.9.0

It is recommended to install these packages in a conda environment using conda and to use "Spyder" as an scientific environment. The dependencies of OPT is easily installed by running the Install_dependencies.bat file in the "Anaconda Prompt"

What follows is a basic tutorial for beginners to python3 on how to setup python3 inside a conda environment and then install the required packages.

  1. Install Anaconda (or Miniconda if prefered) from their website.

One instance of Python3 is installed together with Anaconda (or Miniconda) inside the conda environment. Anaconda comes with many preinstalled python packages, and some of the ones required by Operational Planning Tool may already be installed (scipy for example). Miniconda comes with no preinstalled packages and also no graphical interface.

  1. After installation open the program "Anaconda Prompt".

  2. Run these commands in the "Anaconda Prompt" to install the desired packages. Alternatively run the Install_dependencies.bat file in the "Anaconda Prompt" program.

$ conda install -c anaconda ephem=3.7.6.0

$ conda install -c conda-forge matplotlib=3.1.1

$ conda install -c anaconda scipy=1.2.1

$ conda install -c anaconda lxml=4.3.3

$ conda install astropy=4.0

$ conda install -c astropy astroquery=0.3.10

$ conda install pip

$ conda install -c anaconda h5py=2.9.0

$ conda install -c conda-forge skyfield=1.13

  1. Run the following command to list all currently installed packages and their version number.

$ conda list

  1. Then install Spyder by once again using the "Anaconda Prompt".

$ conda install spyder

  1. Run Spyder and create a project (found at the toolbar at the top). Place the OPT (Operational_Planning_Tool) package in the working directory of the project.

The OPT (Operational_Planning_Tool) package can be put anywhere in sys.path but it is easiest to put it in the working directory of the Spyder project, as that directory is automatically part of the PYTHONPATH which is part of sys.path.

  1. Allow plots created with python to be printed in separate windows. Go to tools/preferences in Spyder. Then in the preferences window, select "IPython Console". Go to Graphics. In the dropdown menu of "Graphics backend" select automatic.

  2. Finally try to execute these lines in Spyder (either in the IPython console or as part of a script).

    import OPT

    OPT.Copy_ConfigFile('OPT_Config_File')

    OPT.Set_ConfigFile('OPT_Config_File')

    OPT.CheckConfigFile()

    OPT.Timeline_gen()

    OPT.XML_gen('Output/Science_Mode_Timeline__OPT_Config_File.json')

    Data_MATS, Data_LP, Time, Time_OHB = OPT.Timeline_Plotter('Output/Science_Mode_Timeline__OPT_Config_File.json')

See further documentation found under "Docs" in OPT (Operational_Planning_Tool) to learn how to use the OPT package. The docs are automatically generated from the source code by using the python package Sphinx. The documentation is saved in OPT_Build_Extensive and OPT_Build_Simplified, where the extensive one contains documentation about every part of OPT, including private modules and packages, while the simplified one only contains information about the public functions which are meant to be used by the user. To rebuild the documentation, simply run the Sphinx_CMD_File.bat in the anaconda prompt (requires installation of sphinx package).

mats-planningtool's People

Contributors

sckanberg avatar olemartinchristensen 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.