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.4.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | a90bb4a34ec84987df9b310d086757a060210de372333772f598f9cae55a7e74 |
|
MD5 | aae3aa942b0126f3edf0709c29377e61 |
|
BLAKE2b-256 | 670685e7ad837c3f5e9a4d3f0867d1a3e251544f54bde52b36d6e1954bead5e3 |
Close
Hashes for logiclayer_complexity-0.4.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d2d12dc9ea50278608e2c6191a3fa9011d95e14045ddae087374817ce2a54e00 |
|
MD5 | 1e1c3f6c452da40462b8cb71c1a515a5 |
|
BLAKE2b-256 | 93295444746b4e98770833371a5a5bd38ea1d9dabecf1eaecd252a2971e8b54f |