Spaces:
Running
Running
import streamlit as st | |
from datasets import load_dataset, Image | |
from huggingface_hub import hf_hub_download | |
pip install joblib | |
import joblib | |
REPO_ID = "jableable/road_project" | |
FILENAME = "best_model.keras" | |
model = joblib.load( | |
hf_hub_download(repo_id=REPO_ID, filename=FILENAME) | |
) | |
x = st.slider('Select a value') | |
st.write(x, 'squared is', x * x) | |
loaded_model = keras.saving.load_model("best_model.keras") | |
dataset = load_dataset("beans", split="train") | |
loaded_img = dataset[0]["image"] | |
print(loaded_img) | |