LogicLayer module to enable Economic Complexity calculations, using data from a tesseract-olap server.
Project description
Getting started
This module must be used with LogicLayer. An instance of OlapServer
from the tesseract_olap
package is also required to retrieve the data.
# app.py
from logiclayer import LogicLayer
from logiclayer_complexity import EconomicComplexityModule
from tesseract_olap import OlapServer
from tesseract_olap.logiclayer import TesseractModule
layer = LogicLayer()
olap = OlapServer(backend="clickhouse://...", schema="./schema/")
cmplx = EconomicComplexityModule(olap)
layer.add_module("/complexity", cmplx)
# You can reuse the `olap` object with an instace of `TesseractModule`
tsrc = TesseractModule(olap)
layer.add_module("/tesseract", tsrc)
You can also use the module with a FastAPI instance:
cmplx = EconomicComplexityModule(olap)
app = FastAPI()
app.include_router(cmplx.router, prefix="/complexity")
© 2022 Datawheel, LLC.
This project is licensed under MIT.
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
Built Distribution
Close
Hashes for logiclayer_complexity-0.5.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4cc8b3f446820af7535c1805ae7d76380b03de1f06ff6e0495ddc049619bfc65 |
|
MD5 | 6e825d1b08fd47d313f7b760bc53b4fa |
|
BLAKE2b-256 | 195e6eb2226853774152bf7c8c880a646419cf95d1ad37d8580898264c6cbdf4 |
Close
Hashes for logiclayer_complexity-0.5.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | c9f5b3418ce730eaddf0b28f8f0c6dfe8cf6e9829f8fbeb3625585ab5017f96a |
|
MD5 | 03ce21953f9565fbf5cdbc87e0f8adc3 |
|
BLAKE2b-256 | 05968d90295088bfd07a05f2d2b16e1e23f8b1873dc5f2fb6a5a380f8eb6b5d2 |