Skip to main content

Common functions, classes and interfaces that CrossTech uses in its python development.

Project description

CrossTech-Py-Tools

Commonly used python functions and interfaces for CrossTech python development. If you are a developer of this library check out this documentation.

Install

To install the library use the commands provided below.

pip:

pip install crosstech-py-tools

poetry:

poetry add crosstech-py-tools

[!WARNING] When trying to add this library to an existing project using poetry, be aware that it is reliant on a large number of dependencies, meaning adding it will require some labour to sort out any conflicts. Hence, it is recommended to start your project by adding this library first.

Modules

Cloud Funcs

☁️ Cloud Funcs documentation. This module focuses on simplifying the process of testing cloud functions by simulated calls in-code. It provides a wrapper make_request around Flask call, which removes the boilerplate code needed to call the cloud function normally.

from crosstech.clound_funcs import make_request

Database

💽 Database documentation. This module provides a database interface that is proven to work in cloud functions. The BaseDB object can be used in an inheritance relationship or be injected into a function. Either way, this will save time on setting up the boilerplate necessary to connect to the database.

from crosstech.database import BaseDB

Location

🗺️ Location documentation. This module contains an array of tools useful for analysing and manipulating location data.

The explore function can take in geopandas GeoDataFrames and plot them all on a single map. The LocTools object helps with converiting between shapely points and latitude & longitude pairs and vice versa, as well as extracting points from mileages for an ELR. Finally, TrackGeoJSON object serves to assist in downloading track geojsons using a single function.

from crosstech.location import explore, LocTools, TrackGeoJSON

Mileage

🚂 Mileage documentation. This module contains an object which helps in converting mileages from Miles.Yards to decimal miles, or Miles.Chains to decimal miles, and vice versa.

from crosstech.mileage import MilesYards

ELRs

👷 ELRs documentation This module contains objects that help with downloading our Network Models. For more extensive documentation about the Network Model see this article.

from crosstech.elrs import FullModel, SimplifiedModel

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

crosstech_py_tools-0.2.11.tar.gz (24.2 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

crosstech_py_tools-0.2.11-py3-none-any.whl (24.4 MB view details)

Uploaded Python 3

File details

Details for the file crosstech_py_tools-0.2.11.tar.gz.

File metadata

  • Download URL: crosstech_py_tools-0.2.11.tar.gz
  • Upload date:
  • Size: 24.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.8.3 CPython/3.11.7 Windows/10

File hashes

Hashes for crosstech_py_tools-0.2.11.tar.gz
Algorithm Hash digest
SHA256 84e59c6b6261f69083aa9b0f9efa06e5b37a6549387fbac2b51a4d17e8043ff1
MD5 c618dabeaa2f1ff1941d9075582fe7e8
BLAKE2b-256 7f387fc3c03fed6060f88d537010dee4a0e74de8df46ffffac77b57828b631b8

See more details on using hashes here.

File details

Details for the file crosstech_py_tools-0.2.11-py3-none-any.whl.

File metadata

File hashes

Hashes for crosstech_py_tools-0.2.11-py3-none-any.whl
Algorithm Hash digest
SHA256 a0f58c6887220eef5bc04f30b9d8e1fe89134f09aa9ba3cfe83b9ee3e523ca04
MD5 e824a0f6826137cbcf3a508a7d57747b
BLAKE2b-256 57b6ac5aa669bbcb38096d75e3dbd9870e698281e6135c1a069ee8a3e3ba3e80

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page