Skip to main content

Civil Engineering Tools in Python

Project description

CivilPy

PyPI - License Project badge PyPI - Python Version Project badge PyPI Downloads

Source Code

Code snippets for Civil Engineering related tasks

About (Skip to the "Installation" section to start running code)

Welcome to the CivilPy repository. This is a simple software package to give civil engineers cleaner access to some of the packages from the python ecosystem. The package is focused on civil engineering related tasks such as file management, pdf data extraction, image manipulation mapping and unit conversions. I did my best to make the user interface obvious to use and tried to keep the functionality compatible with tools available to the average Civil engineer.

Intro

This repository was created in order for me to gain a better understanding of software development work flows and how they can be re-purposed for civil engineering related tasks. This is by no means a comprehensive or even functional repository but is more a way for me to track my progress while learning more about another industry. There may occasionally be how-tos and other code posted here but this repository is not meant as tutorial or in depth explanation for how coding works. For those types of things I highly suggest you instead check Youtube for general lessons or Stack Overflow for specific issues. I highly recommend the Harvard CS50 YouTube Channel for conceptual level programming lessons or CoreyMS's Youtube Channel for lessons in practical uses of programming.

For an interesting somewhat working examples see the files Useful Tricks and Tools.ipynb and NBI STandards - Conversion files to have a better understanding of what function the DOT/SNBI files are performing.

Installation

Run the following code to install the package:

$ pip install civilpy

Usage

to check the package installed correctly, run:

from civilpy.structural.steel import W

# Load a W steel section as a python object
W40X390 = W("W40X390")
W40X390.A

Contributing

Clone, ctl+f, "# //TODO -"

For PRs reach out to me on github or at dane@daneparks.com. Github version of the libary is a mirror that often falls out of date whenever a large file sneaks into the repo.

How to determine where to store functions within the package

Here is the decision tree for function organization within the package, the goal is to keep importing and running functions as simple as possible for non-programmers, while maintaining an organizational structure capable of supporting many tools.

i.e., the end user should be able to access any of your functions from a simple import:

from civilpy.state.ohio.DOT.legacy import help_function
graph TD
    A[Does the function more relate to a particular state<br> requirement/system, or a branch of Civil Engineering?] --> |State| B("Does it apply state wide <br> or a specific department?")
    A --> |Branch| C("Which branch does it most closely fit? ")
    C --> |construction| D(Save under <br> civilpy.construction)
    C --> |structural| E(Save under <br> civilpy.structural)
    C --> |geotechnical| F(Save under <br> civilpy.geotechnical)
    C --> |environmental| G(Save under <br> civilpy.environmental)
    C --> |transportation| H(Save under <br> civilpy.transportation)
    C --> |water_resources| I(Save under <br> civilpy.water_resources)
    A --> |Neither| P
    D --> K("Is it related to a particular standard, (i.e. AASHTO)")
    E --> K
    F --> K
    G --> K
    H --> K
    I --> K
    B --> |Statewide| L("civilpy.[state].__init__.py")
    B --> |Department| M("civilpy.[state].department")
    K --> |Yes| N("Save under a file for the standard<br>i.e. civilpy.structural.aisc")
    K --> |No| O("save to the relevant __init__.py")
    P("Save under civilpy.general.[relevant_file]")
    N --> |Doesn't make sense to put it there| P
    O --> |Doesn't make sense to put it there|P

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

civilpy-0.1.36.tar.gz (1.1 MB view details)

Uploaded Source

Built Distribution

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

civilpy-0.1.36-py3-none-any.whl (1.1 MB view details)

Uploaded Python 3

File details

Details for the file civilpy-0.1.36.tar.gz.

File metadata

  • Download URL: civilpy-0.1.36.tar.gz
  • Upload date:
  • Size: 1.1 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.14

File hashes

Hashes for civilpy-0.1.36.tar.gz
Algorithm Hash digest
SHA256 120b7510a50730dd08ff37cc128316f845998072ebc05d00d933d5df8478d2fc
MD5 3005ec118e8a631e1f7ced6c6f45d209
BLAKE2b-256 cccdf8840a7e6bda1298d83370c00398ae975232ddd4255c4f1c313759e5592c

See more details on using hashes here.

File details

Details for the file civilpy-0.1.36-py3-none-any.whl.

File metadata

  • Download URL: civilpy-0.1.36-py3-none-any.whl
  • Upload date:
  • Size: 1.1 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.14

File hashes

Hashes for civilpy-0.1.36-py3-none-any.whl
Algorithm Hash digest
SHA256 133e46792ab18dc17af48c39133a9340ec44fb1c45e8c6cc0ef533290a44c170
MD5 e8e95c1e0293f39a3149f415e6320e8b
BLAKE2b-256 a5eaf0d484a11aa603e9691f95efdf94f166fa7366125b332c0be7eca0cbb086

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