Main setup function
()
| 101 | return True |
| 102 | |
| 103 | def main(): |
| 104 | """Main setup function""" |
| 105 | print("🚀 Setting up Ocean Hazard System Python Environment") |
| 106 | print("=" * 50) |
| 107 | |
| 108 | # Check Python version |
| 109 | if not check_python_version(): |
| 110 | sys.exit(1) |
| 111 | |
| 112 | # Install requirements |
| 113 | if not install_requirements(): |
| 114 | print("❌ Failed to install requirements") |
| 115 | sys.exit(1) |
| 116 | |
| 117 | # Install spaCy model |
| 118 | if not install_spacy_model(): |
| 119 | print("⚠️ Warning: Failed to install spaCy model") |
| 120 | |
| 121 | # Download NLTK data |
| 122 | if not download_nltk_data(): |
| 123 | print("⚠️ Warning: Failed to download NLTK data") |
| 124 | |
| 125 | # Create data directories |
| 126 | create_data_directories() |
| 127 | |
| 128 | # Test imports |
| 129 | if not test_imports(): |
| 130 | print("❌ Some modules failed to import") |
| 131 | sys.exit(1) |
| 132 | |
| 133 | print("\n" + "=" * 50) |
| 134 | print("🎉 Python environment setup completed successfully!") |
| 135 | print("\nNext steps:") |
| 136 | print("1. Set up your API keys in a .env file") |
| 137 | print("2. Test the data processing pipeline") |
| 138 | print("3. Run the social media extractors") |
| 139 | |
| 140 | if __name__ == "__main__": |
| 141 | main() |
no test coverage detected