Installation ============ This library has a number of dependencies, most notably the `traffic `_ library, for which you can find installation instructions `here `_. The library also relies on `scipy `_ and `numpy `_ for data types and mathematical functions, and `pandas `_, `geopandas `_, and `Shapely `_ for processing airspace data. Visualisations are provided through `matplotlib `_, `cartopy `_, `pyproj `_, and `hvplot `_. The `simplejson `_ library enables data exporting, and `networkx `_ is used to build directed graphs. .. warning:: Certain dependencies (particularly `cartopy` and `shapely`) require access to libraries which may not be present on the system. The `Anaconda `_ platform is much better at handling these dependencies - if possible, install it first then run the following: .. parsed-literal:: conda install cartopy shapely pip install flight_processing Additional dependencies can also be installed using Anaconda if desired. Installation using pip ---------------------- This package is not yet available on PyPI but on certain compatible systems may be able to be installed using pip: .. parsed-literal:: wget https://github.com/jsmailes/flight_processing/releases/download/v1.0.0/flight_processing-1.0.0-cp37-cp37m-linux_x86_64.whl pip install flight_processing-1.0.0-cp37-cp37m-linux_x86_64.whl Manual build and installation ------------------------------ We can also build and install the package manually using python's ``setuptools``. Install prerequisites ~~~~~~~~~~~~~~~~~~~~~ Building the package requires a number of prerequisites, both to compile the C++ component and to install the python library itself. First install the following using your package manager: .. code-block:: none git cmake gcc-c++ python3 boost-devel boost-python3-devel boost-numpy3 .. note:: The above package names are correct on Fedora Linux, but they may differ depending on your operating system. The following package names can be used on Ubuntu: .. code-block:: none git cmake g++ python3-dev libboost-all-dev Next we need to install some python prerequisites: .. parsed-literal:: pip install setuptools wheel Clone repository ~~~~~~~~~~~~~~~~ Now we clone the repository from Github: .. parsed-literal:: git clone --recurse-submodules https://github.com/jsmailes/flight_processing cd flight_processing Build wheel (optional) ~~~~~~~~~~~~~~~~~~~~~~ To build a wheel and/or source tarball using ``setuptools``, run the following: .. parsed-literal:: python3 setup.py sdist bdist_wheel These can then be installed using ``pip`` if desired. Install ~~~~~~~ Installation is fairly straightforward, since ``pip`` installs the prerequisites and runs ``setup.py`` for us: .. parsed-literal:: pip install . .. note:: Instead of cloning and building the repository, you can download and build the tarball distributed on the `releases page `_. This will have the same result as cloning and building the source repository but does not require the use of git. The C++ dependencies will still need to be installed for this method of installation. .. parsed-literal:: wget https://github.com/jsmailes/flight_processing/releases/download/v1.0.0/flight_processing-1.0.0.tar.gz pip install flight_processing-1.0.0.tar.gz Troubleshooting ~~~~~~~~~~~~~~~ Issues with python dependencies can usually be fixed by installing them using `Anaconda `_. Cryptic issues with CMake are usually caused by having an incorrect version of Python and/or Boost installed. If you're having any more problems, please `create an issue `_ on the Github repo with some details about your system and the problem you're having.