Questions tagged [streamlit]
Questions about Streamlit and custom machine learning models in Streamlit.
779
questions
1
vote
0
answers
7
views
ca not open execute file from python script due to no package metadata for streamlit
I wrote a script in python and one of the packages I have used was streamlit 1.9.0
after finishing I have tried to create the .exe file via pyinstaller
but unfortunately I can use the exe file because ...
0
votes
1
answer
13
views
module 'pyrebase' has no attribute 'initialize_app'
I currently use streamlit and wanted to integrate to firebase. I have been encountered the problem "no module named 'pyrebased'" and finally can install it.
however I face another problem ...
0
votes
0
answers
12
views
streamlit usage with bootstrap cards tabs
I have a streamlit app that i added bootsrtap cards in order to display the content of a dataframe.
The problem is that i need a add to the bootstrap card many tabs, when i try it i doesn't work and ...
0
votes
0
answers
10
views
Streamlit Autocomplete from list of values
I want to provide suggestions / autocomplete based on a list of values in text_input in streamlit
text_input(label = "select location", max_chars=200, placeholder="<...
1
vote
2
answers
32
views
How can i save the uploaded pdf file using Streamlit Python?
I have created a form with multiple text input values and one pdf upload. But I also want to save the pdf file uploaded to one my directory folder , How can I do that?
st.title("Demo")
st....
0
votes
0
answers
6
views
Error "StreamModeError: Fasta files must be opened in text mode" in BioPython on a Streamlit App
Please Assist, How can I resolve this Error?
I am building a streamlit app that take uploaded FASTA Files as input and read them.
I am getting the error below when I try to read an uploaded fasta file ...
0
votes
0
answers
21
views
Having problem displaying dataframe with streamlit
data_to_graph = combined_summary_df.unstack(level=1, fill_value=0)
with st.expander("Where to test everything related to graph"):
st.write(data_to_graph)
"I am new to Streamlit. I ...
1
vote
0
answers
20
views
Streamlit plot 2 graphs
I'm new in Python and Streamlit, I have issues to plot two graphs on Streamlit.
On jupyter notebook it's working very well with this code:
train_size = X_train.shape[0]
f,axs = plt.subplots(1,2,...
2
votes
0
answers
25
views
Problem with update select widget and customJS bokeh for streamlit app
I have a problem with the customJS callback for a streamlit application.
The following code works to display the graph, but the callback doesn't work and I don't practice JavaScript.
When I change the ...
0
votes
0
answers
31
views
AWS cognito logging out with Streamlit (python)
I built a simple application using Streamlit (python) and AWS Cognito. I managed to set up a user pool and access to the application through an application load balancer and Fargate.
However, although ...
0
votes
1
answer
58
views
Controlling Streamlit st_aggrid (AgGrid) layout by placing grid inside an st.container, st.column, or st.empty
Python 3.8.10
Ubuntu 20.04
Using st_aggrid (the Python port of AgGrid for Streamlit.)
Streamlit allows for layout control using st.column, st.empty, and st.container. The format is (for example)...
...
0
votes
1
answer
43
views
How to use if statment inside div tags with streamlit (bootstrap card)
How to use if statement inside div tags with streamlit ?
I am using bootstrap card with streamlit to display info from dataframe .
What i need is to be able to display the content inside the ...
0
votes
1
answer
30
views
Streamlit image not being updated
I am pretty new to the Python world and Streamlit, and trying to set up a small app with Streamlit that connects to a websocket and updates the image on every message. I have the following two files ...
0
votes
1
answer
44
views
I don't understand the error message - Streamlit app
I have a streamlit app that I wrote on other computer and it was running smoothly. because I needed to change computers, I cloned it from my repo to the new computer and created directory with env for ...
0
votes
1
answer
22
views
Text align in streamlit st.info information box
How to align text (justify) in streamlit information box(st.info)
import streamlit as st
# Generate Three equal columns
c1, c2, c3 = st.columns((1, 1, 1))
with c1:
st.info("""...
-4
votes
1
answer
59
views
ModuleNotFoundError: No module named ‘cv2’
I am getting this error when trying to deploy my streamlit app. It runs perfectly when I execute it through vscode. How to fix it?
File "/home/appuser/venv/lib/python3.9/site-packages/streamlit/...
0
votes
2
answers
36
views
How to make docker-build to cache the pip installs as well?
I am working with the following Dockerfile.
FROM ubuntu
RUN apt-get update
RUN apt-get install -y \
python3.9 \
python3-pip
COPY . /app
WORKDIR /app
RUN pip install -r requirements.txt
...
0
votes
0
answers
16
views
Failed to complete tunnel connection in ngrok (Google colabs)
I've been trying to run my web app using ngrok, when I click on the created url it say
The connection to http://XXXXX.ngrok.io was successfully tunneled to
your ngrok client, but the client failed ...
-1
votes
0
answers
23
views
Update Query error:Not all parameters were used in the SQL statement [duplicate]
I'm working with streamlit, pandas, Mysql and AG-grid
I've got some help here before which I'm very grateful but I encountered another issue when I moved from SQLite to MySQL
my goal is to create a ...
0
votes
1
answer
31
views
model.predict gives an error could not convert string to float
I'm using Streamlit to build a machine learning model to predict the price of a car.
After splitting the data into train and test and choosing the best model,
I need to predict the price of a car ...
1
vote
0
answers
19
views
Streamlit file_uploader - EmptyDataError: No columns to parse from file, TypeError: expected str, bytes or os.PathLike object, not NoneType
I built a streamlit app where one can upload csv, xls, xlsx files.
And I'm loading the uploaded files using below functions load_data, load_excel
# Load dataset
@st.cache(allow_output_mutation=True)
...
0
votes
1
answer
34
views
The streamlit does not refresh the dataframe on the localhost
I am New in pandas and streamlit , What I am trying is to filter such a dataframe using streamlit selectbox
but unfortunately everything is going well except that when changing the filter value it ...
0
votes
0
answers
24
views
Why do I have "recursion depth exceeded while calling a Python object" while deploying streamlit app? [duplicate]
I try to deploy my streamlit project, and in the localhost it works perfectly. But when I try to deploy the app at Streamlit, it prints "recursion depth exceeded while calling a Python object&...
0
votes
0
answers
42
views
How to commit the update on the SQL database after edit the dataframe using st.aggrid in streamlit and python
I am using the st_aggrid component with connection with database what I want is to allow the user user to edit a column value using st_aggrid than after edit is done its commit on the database how can ...
0
votes
1
answer
42
views
error when running streamline as frontend and FastAPI as backend
I have developed a machine learning app with fastapi as the backend, and streamlit as the frontend, it works on my local machine when I run it, i am abe to generate th predictions using the streamlit ...
0
votes
1
answer
27
views
Column names not displayed with st.dataframe after PostgreSQL `SELECT *` into Pandas DataFrame
Python 3.8.10
streamlit==1.9.0
pandas==1.4.2
psycopg2-binary==2.9.3
Loading a Postgres table directly into a Pandas DataFrame with the following code.
df = pd.DataFrame(run_query("SELECT * FROM ...
0
votes
0
answers
25
views
I have an error in docker-compose about undefined network,
I am trying to dockerize two applications, one being streamlit, the other being fastapi, I have built the individual docker images for them, and now trying to run them at the same time so they ...
0
votes
0
answers
22
views
Streamlit file uploader error in VCF file format
I want to read vcf file using streamlit file uploader. but i am getting TypeError: expected str, bytes or os.PathLike object, not UploadedFile
import io.
import os
import pandas as pd
import streamlit ...
0
votes
0
answers
18
views
Add ResearchGate profile to personal website
I have been trying to build a portfolio for myself where I have added Stackoverflow 'flair' & LinkedIn 'Badge' by embedding js scripts in streamlit. Can the same be done for Researchgate as well? ...
0
votes
1
answer
69
views
Is there any way to share images between two streamlit webapps?
I want to link 2 web pages made using streamlit and hosted using Heroku. One of them removes the image background and the other does an image classification task. (They could not be made into one due ...
2
votes
3
answers
51
views
HTML, Customization Problems in Web Page's Footer Section
The code: (Between footer=""" and """ includes html format code)
footer="""<meta name="viewport" content="width=device-width, initial-...
1
vote
2
answers
52
views
St.Success of Customization Problems (Streamlit)
Is there any way to change the font and background color, and opacity of st.success ? Because anything doesn’t seem with default colors.
Here a visual for the problem:
0
votes
0
answers
20
views
Streamlit Deploy Platform or Hosting Service
So I have a Python Streamlit Source Code and it has a massive size model, in total of around 4-5GB.
Is there any Hosting Service or Platform where could i deploy my Streamlit Project to?
Something ...
0
votes
1
answer
11
views
My Plotly plots are cut off in my Streamlit app
I'm plotting some data in Streamlit and the site looks great on my desktop.
However when I view it on my mobile device the right side is cut off.
My code:
fig = go.Figure()
fig.add_trace(go.Scatter(x=[...
1
vote
1
answer
27
views
How to open url from altair chart in a new tab (href)
I've made an altair scattered chart with links.
It works perfectly from my Jupyter Notebook.
Problems start when altair is in Streamlit environment. As I investigated, my app with altair chart is ...
0
votes
0
answers
50
views
List of chooses depending on user permissions
I'm building simple app on streamlit. I'm struggling with making list of chooses depending on user permissions.
utils.py
Dict with pages:
pages = {
"Start": start_page,
"Test ...
0
votes
1
answer
29
views
How to make graph using streamlit with the widget, but theres multiple widget?
so i want to make callback graph that can display the graph within theres two widget there (radio and selectbox), but i have some problem in here, the radio button (gender clasify) theres no change ...
0
votes
1
answer
55
views
How to access the save results of yolov5 in different folder?
I am using the below code to load the trained custom Yolov5 model and perform detections.
import cv2
import torch
from PIL import Image
model = torch.hub.load('ultralytics/yolov5', 'custom',
path='...
0
votes
0
answers
11
views
Failure to build pyarrow numpy when pip installing streamlit, python 3.9.4
I get the following error when I pip install streamlit:
Failed to build pyarrow numpy
ERROR: Could not build wheels for pyarrow, numpy which use PEP 517 and cannot be installed directly
0
votes
0
answers
33
views
Graph display incorrectly
Problem with my project, the graph seems to be not centered.
This error occur: \site-packages\plotly\matplotlylib\renderer.py:611: UserWarning:I found a path object that I don't think is part of a bar ...
0
votes
0
answers
35
views
How to get updated bokeh graph in streamlit (server issue?)
I want to embed a bokeh graphic in streamlit. the interactive bokeh graph is operational with the command boker serve --show application.
But when I integrate it into streamlit, I have the graph that ...
0
votes
1
answer
24
views
Running streamlit with tensorflow causes crash when loading model
When running
model = load_model('path_to_model',custom_objects={'my_cutome_activation': my_cutome_activation})
Causes a crash
layer = deserialize_layer(layer_data, custom_objects=custom_objects)
...
0
votes
1
answer
62
views
ModuleNotFoundError: No module named 'pyarrow.lib'
This is the full error message.
Traceback (most recent call last):
File "C:\Users\adi\OneDrive\Desktop\Python310\machine learning project.py", line 3, in <module>
import ...
0
votes
1
answer
60
views
Streamlit: pass the widget input to its own callback
I'd like to capture a text in a streamlit text_area widget (for instance, but any widget that produces input should work the same), and pass the captured text to the callback. How could I do that ? (...
0
votes
0
answers
21
views
Stale element reference exception - Selenium
so I am creating a testing framework for a webapp but first I have to login to the site in order to begin the tests. My problem is that the login is in two parts, first page where you enter your email ...
0
votes
1
answer
76
views
save the AgGrid data to sqlite with python
Hi im building an app to save results of projects that we do at work
and I want to update a table with aggrid and it will also update the sqlite DB that im using
I manage to edit on the web app but it ...
0
votes
0
answers
34
views
Python/Linux/Streamlit: executing subprocess for linux script
I'm a bit turned around on how to execute a shell script file in a Linux environment via Python's subprocess command in Streamlit. Any assistance on what I'm missing is appreciated.
I'm using a shell ...
0
votes
1
answer
49
views
how do I resize the image shown by st.image
I have the following code:
bottom_image = st.file_uploader('', type='jpg', key=6)
if bottom_image is not None:
st.image(bottom_image)
the problem I run into is some of the images are very large ...
1
vote
1
answer
38
views
My streamlit app opens in a browser but it is blank and shows 'client connecting' only
I deployed my streamlit using github at streamlit.io, and i couldn't open it in my chrome, it keeps showing "[client] Connecting.." and it took forever. The error shown in my chrome console:
...
0
votes
0
answers
46
views
tensorflow module not found, while using streamlit
PS D:\projects\fashion-recommender-system> streamlit run main1.py
You can now view your Streamlit app in your browser.
Local URL: http://localhost:8501
Network URL: http://192.168.1.213:8501
2022-...