Web Framework for MI and AI applications
Project description
Zig
Zig is an open-source Python Webapp Framework for ML, Data Science and analytics applications. Creates webapp easily using other Python ML-related libraries (Pandas) and Plotly without any frontend knowlegde.
Zig can be configured to use Flask(default), Django or other Python web frameworks, while the frontend is rendered by our Angular Library.
Installation
Use the package manager pip, or pipenv(virtual env) to install Zig.
pip install zig
Or with virtual environment,
pipenv install zig
Usage
from zig import Zig
from zig.main_components import Graph
from zig.html_components import *
import pandas as pd
from ploty.express import bar
app = Zig("app_name")
df = pd.DataFrame({
"Phone OS": ["IOS", "Android", "IOS", "Android", "IOS", "Android"],
"Amount": [400, 500, 300, 700, 200, 900],
"City": ["SF", "NY", "SF", "NY", "SF", "NY"]
})
fig = bar(df, x="Phone OS", y="Amount", color="City", barmode="group")
# Zig provides nested sections and introspection of sections
# with reusable components that can be passed around
div = Div().add(P("This is your first graph!"))
div.add(Graph(fig))
# Makes coding webapp clean and simple
app.add(div)
# Starts a local dev server on localhost. Uses Flask as default
app.run()
Contributing
Angular library is on https://github.com/EdenInTheEast/zig-angular
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
Please make sure to update tests as appropriate.
License
MIT License
Copyright (c) [2021] [kib]
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
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
File details
Details for the file zig-1.0.dev0.tar.gz
.
File metadata
- Download URL: zig-1.0.dev0.tar.gz
- Upload date:
- Size: 6.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2760c5600d4c6e17f9709971287cf1d0f90495e81966afe097b9698002d62663 |
|
MD5 | 1e8fd61a6009fd220b98f5a5e8e4fed7 |
|
BLAKE2b-256 | 06d967f9fdb9b5112ff9d885ac2dcf054b884c50eec9287ee3eb34fb4af213cd |
File details
Details for the file zig-1.0.dev0-py3-none-any.whl
.
File metadata
- Download URL: zig-1.0.dev0-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.4.1 importlib_metadata/4.0.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.60.0 CPython/3.8.8
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0881fd614e4f701dfb5bfddf245eb4f7cdbe250169f3bafa8dad8b6d0d0b1659 |
|
MD5 | b98854e8b07eeeb745ef8de825535adc |
|
BLAKE2b-256 | a1ab22f308dc6aa7eb5a5b2a43c9e8686f55cbfa4735b6c279f3a3408faae97e |