PrakhAI's picture
Update app.py
c7ef840
raw
history blame
377 Bytes
import streamlit as st
from huggingface_hub import HfFileSystem
from flax.serialization import msgpack_restore, from_state_dict
fs = HfFileSystem()
with fs.open("PrakhAI/HelloWorld/checkpoint.msgpack", "rb") as f:
state_dict = msgpack_restore(f.read())
print(state_dict)
print(state_dict.keys())
x = st.slider('Select a value')
st.write(x, 'squared is', x * x)