Skip to content
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

launching AlphaPept GUI failed #564

Open
Chuanping-Zhao opened this issue Sep 9, 2024 · 0 comments
Open

launching AlphaPept GUI failed #564

Chuanping-Zhao opened this issue Sep 9, 2024 · 0 comments

Comments

@Chuanping-Zhao
Copy link

Describe the bug
When attempting to start the AlphaPept GUI using Streamlit, an AttributeError is raised related to the numpy.typing module not having an attribute NDArray. This error prevents the AlphaPept GUI from launching correctly.

To Reproduce
Steps to reproduce the behavior:
Activate the Conda environment with conda activate alphapept.
conda activate alphapept
Run alphapept gui.
alphapept gui
The GUI initialization begins and loads several modules.
The error occurs during the import sequence, particularly when importing PIL (Python Imaging Library) which in turn requires numpy.typing.NDArray, leading to a crash.
AttributeError: module 'numpy.typing' has no attribute 'NDArray' Traceback: File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\streamlit\runtime\scriptrunner\exec_code.py", line 88, in exec_func_with_error_handling result = func() File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\streamlit\runtime\scriptrunner\script_runner.py", line 590, in code_to_exec exec(code, module.__dict__) File "D:\softwares_pathway\Anaconda3\envs\alphapept\Lib\site-packages\alphapept\webui.py", line 2, in <module> from alphapept.gui import history, results, filewatcher, status, experiment, fasta, start, constants File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\alphapept\gui\history.py", line 4, in <module> import plotly.express as px File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\plotly\express\__init__.py", line 14, in <module> from ._imshow import imshow File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\plotly\express\_imshow.py", line 8, in <module> from plotly.utils import image_array_to_data_uri File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\plotly\utils.py", line 5, in <module> from _plotly_utils.data_utils import * File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\_plotly_utils\data_utils.py", line 6, in <module> from PIL import Image File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\PIL\Image.py", line 68, in <module> from ._typing import StrOrBytesPath, TypeGuard File "D:\softwares_pathway\Anaconda3\envs\alphapept\lib\site-packages\PIL\_typing.py", line 10, in <module> NumpyArray = npt.NDArray[Any]
image

Expected behavior
I expected the AlphaPept GUI to launch and operate without any import errors or crashes, allowing for typical usage such as file management and experiment handling within the interface.

Version
Windows 11
Version: AlphaPept 0.5.3
Installation Type: Conda environment

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant