Spaces:
Sleeping
Sleeping
new app
Browse files- app.py +17 -0
- images/banner.png +0 -0
- requirements.txt +1 -0
app.py
CHANGED
@@ -266,8 +266,25 @@ def perform_inference(model_object, model_arrow, image, score_threshold):
|
|
266 |
def get_image(uploaded_file):
|
267 |
return Image.open(uploaded_file).convert('RGB')
|
268 |
|
|
|
269 |
def main():
|
270 |
st.set_page_config(layout="wide")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
271 |
st.title("BPMN model recognition demo")
|
272 |
|
273 |
# Display current memory usage
|
|
|
266 |
def get_image(uploaded_file):
|
267 |
return Image.open(uploaded_file).convert('RGB')
|
268 |
|
269 |
+
|
270 |
def main():
|
271 |
st.set_page_config(layout="wide")
|
272 |
+
|
273 |
+
# Add your company logo banner
|
274 |
+
st.image("./images/banner.png", use_column_width=True)
|
275 |
+
|
276 |
+
# Sidebar content
|
277 |
+
st.sidebar.header("This BPMN model recognition by AI is proposed by ELCA in collaboration with EPFL.")
|
278 |
+
st.sidebar.subheader("Instructions:")
|
279 |
+
st.sidebar.text("1. Upload you image")
|
280 |
+
st.sidebar.text("2. Crop the image \n (try to put the BPMN diagram \n in the center of the image)")
|
281 |
+
st.sidebar.text("3. Set the score threshold \n for prediction (default is 0.5)")
|
282 |
+
st.sidebar.text("4. Set the scale for the XML file \n (default is 1.0)")
|
283 |
+
st.sidebar.text("5. Click on 'Launch Prediction'")
|
284 |
+
|
285 |
+
st.sidebar.subheader("You can close the sidebar")
|
286 |
+
|
287 |
+
# Set the title of the app
|
288 |
st.title("BPMN model recognition demo")
|
289 |
|
290 |
# Display current memory usage
|
images/banner.png
ADDED
requirements.txt
CHANGED
@@ -8,3 +8,4 @@ streamlit-cropper==0.2.2
|
|
8 |
streamlit-drawable-canvas==0.9.3
|
9 |
opencv-python
|
10 |
gdown
|
|
|
|
8 |
streamlit-drawable-canvas==0.9.3
|
9 |
opencv-python
|
10 |
gdown
|
11 |
+
psutil
|