Spaces:
Sleeping
Sleeping
| """Test script to check imports and identify version issues""" | |
| import sys | |
| print("Python version:", sys.version) | |
| print("\n" + "="*50) | |
| print("Testing imports...") | |
| print("="*50) | |
| try: | |
| import torch | |
| print(f"β torch: {torch.__version__}") | |
| except Exception as e: | |
| print(f"β torch: {e}") | |
| try: | |
| import transformers | |
| print(f"β transformers: {transformers.__version__}") | |
| except Exception as e: | |
| print(f"β transformers: {e}") | |
| try: | |
| import huggingface_hub | |
| print(f"β huggingface_hub: {huggingface_hub.__version__}") | |
| except Exception as e: | |
| print(f"β huggingface_hub: {e}") | |
| try: | |
| import streamlit | |
| print(f"β streamlit: {streamlit.__version__}") | |
| except Exception as e: | |
| print(f"β streamlit: {e}") | |
| try: | |
| import plotly | |
| print(f"β plotly: {plotly.__version__}") | |
| except Exception as e: | |
| print(f"β plotly: {e}") | |
| try: | |
| import pandas | |
| print(f"β pandas: {pandas.__version__}") | |
| except Exception as e: | |
| print(f"β pandas: {e}") | |
| try: | |
| import numpy | |
| print(f"β numpy: {numpy.__version__}") | |
| except Exception as e: | |
| print(f"β numpy: {e}") | |
| print("\n" + "="*50) | |
| print("Checking transformers dependencies...") | |
| print("="*50) | |
| try: | |
| from transformers import AutoModel, AutoTokenizer | |
| print("β Successfully imported AutoModel and AutoTokenizer") | |
| except Exception as e: | |
| print(f"β Error importing from transformers: {e}") | |
| import traceback | |
| traceback.print_exc() | |