File tree Expand file tree Collapse file tree 4 files changed +2648
-1
lines changed
Expand file tree Collapse file tree 4 files changed +2648
-1
lines changed Original file line number Diff line number Diff line change 77Status: Under development (Working)
88"""
99
10+ import platform
11+
1012import numpy as np
1113import pandas as pd
1214from scipy .spatial .distance import cdist
@@ -269,12 +271,17 @@ def _create_pyclustering_model(
269271
270272 # Build kwargs for pyclustering
271273 kwargs = {}
274+ # Use Python implementation (ccore=False) on macOS to avoid architecture
275+ # compatibility issues with the native C++ library (x86_64 vs arm64)
276+ # On other platforms, use the faster C++ implementation (ccore=True, default)
277+ if platform .system () == "Darwin" : # macOS
278+ kwargs ["ccore" ] = False
272279 if self .distance_metric is not None :
273280 # Map common metric names to pyclustering format if needed
274- kwargs ["ccore" ] = False # Use Python implementation
275281 # Note: pyclustering's distance metric handling varies by algorithm
276282 # For simplicity, we'll let pyclustering use defaults
277283 # Advanced users can modify the model directly if needed
284+ pass
278285
279286 # Import and create the appropriate algorithm
280287 if self .algorithm_name == "kmeans" :
You can’t perform that action at this time.
0 commit comments