nebius/SWE-bench-extra huggingface dataset:
Repository: pysal/esda

Issue:
Bug: ADBSCAN.fit is broken 
https://github.com/pysal/esda/actions/runs/3071277058/jobs/4961813274#step:4:210

It appears that `min_samples` is no longer getting set properly:

```
E           ValueError: min_samples == 0, must be >= 1.
```

Comments:

Patch:
diff --git a/esda/adbscan.py b/esda/adbscan.py
index dbb69e2..6d8444b 100644
--- a/esda/adbscan.py
+++ b/esda/adbscan.py
@@ -247,9 +247,12 @@ def _one_draw(pars):
     if sample_weight is not None:
         thin_sample_weight = sample_weight.iloc[rids]
 
+    min_samples = min_samples * pct_exact
+    min_samples = 1 if min_samples < 1 else int(np.floor(min_samples))
+
     dbs = DBSCAN(
         eps=eps,
-        min_samples=int(np.round(min_samples * pct_exact)),
+        min_samples=min_samples,
         algorithm=algorithm,
         n_jobs=n_jobs,
     ).fit(X_thin[xy], sample_weight=thin_sample_weight)


Test patch:
diff --git a/esda/tests/test_adbscan.py b/esda/tests/test_adbscan.py
index 8440012..ea2434a 100644
--- a/esda/tests/test_adbscan.py
+++ b/esda/tests/test_adbscan.py
@@ -2,7 +2,6 @@ import unittest
 
 import numpy as np
 import pandas
-import pytest
 
 from .. import adbscan
 
@@ -73,9 +72,6 @@ class ADBSCAN_Tester(unittest.TestCase):
             ]
         )
 
-    @pytest.mark.xfail(
-        raises=ValueError, reason="**NEEDS ATTENTION**. Change in scikit-learn>=1.1."
-    )
     def test_adbscan(self):
         # ------------------------#
         #           # Single Core #
@@ -264,9 +260,6 @@ class Get_Cluster_Boundary_Tester(unittest.TestCase):
         _ = ads.fit(self.db, xy=["x", "y"])
         self.labels = pandas.Series(ads.labels_, index=self.db.index)
 
-    @pytest.mark.xfail(
-        raises=ValueError, reason="**NEEDS ATTENTION**. Change in scikit-learn>=1.1."
-    )
     def test_get_cluster_boundary(self):
         # ------------------------#
         #           # Single Core #