INNER CODE UNIT · Python
print_fancy_header
featurestoreorg/serverless-ml-course · src/04-module/cc-fraud-streamlit-ui.py:71
def print_fancy_header(text, font_size=24):
res = f'<span style="color:#ff5f27; font-size: {font_size}px;">{text}</span>'
st.markdown(res, unsafe_allow_html=True)
def transform_preds(predictions):
return ['Fraud' if pred == 1 else 'Not Fraud' for pred in predictions]
progress_bar = st.sidebar.header('⚙️ Working Progress')
progress_bar = st.sidebar.progress(0)
st.title('🆘 Fraud transactions detection 🆘')
st.write(36 * "-")
print_fancy_header('\n📡 Connecting to Hopsworks Feature Store...')
st.write(36 * "-")
print_fancy_header('\n🤖 Connecting to Model Registry on Hopsworks...')
model = get_model(project)
st.write(model)