-
Notifications
You must be signed in to change notification settings - Fork 4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
TypeError: Dataframe.__init__() got an unexpected keyword argument 'height' in visualize.py #150
Comments
Hi @joannaxie612 thanks for filing the issue. Can you list out what commands you ran? I want to try reproducing the issue. Remember that you need the |
Hi @ejm714 , here are the commands I ran: I installed cyfi using pip install (perhaps it was something with package versions/environment caused my issue?).
Then I ran the same sample points as in the tutorial at https://cyfi.drivendata.org/#quickstart in a folder cy_vis in my current directory
This created sentinel_metadata.csv and preds.csv files in the cy_vis folder. Then I ran:
Which then initially led me to encounter the error I described, that was resolved by editing the visualize.py script. After my edit, I could successfully open CyFi Visualize in my browser and results were as expected. The full error message: pd.to_datetime(df.date) - pd.to_timedelta(df.days_before_sample, unit="d") |
Thanks so much for the clear repro instructions! Gradio changed this to |
When running the cyfi visualize command, I encountered the following error:
Copy
TypeError: Dataframe.init() got an unexpected keyword argument 'height'
The error occurs in the visualize.py script, specifically in the gr.DataFrame initialization where the height argument is passed.
This error seemed to resolve after removing the height=200 argument from the gr.DataFrame initialization in visualize.py, which then gave a link to a browser page with the CyFi Explorer.
with gr.Row():
data = gr.DataFrame(
df[
[
"sample_id",
"date",
"latitude",
"longitude",
"density_cells_per_ml",
"severity",
]
].style.format({"density_cells_per_ml": "{:,.0f}"}),
)
The text was updated successfully, but these errors were encountered: