Skip to content

Commit 0a1578c

Browse files
author
brandon
committed
fix merge
1 parent c222e52 commit 0a1578c

File tree

1 file changed

+0
-41
lines changed

1 file changed

+0
-41
lines changed

src/groundlight/client.py

Lines changed: 0 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -1573,47 +1573,6 @@ def create_binary_detector( # noqa: PLR0913 # pylint: disable=too-many-argument
15731573
obj = self.detectors_api.create_detector(detector_creation_input, _request_timeout=DEFAULT_REQUEST_TIMEOUT)
15741574
return obj
15751575

1576-
def create_binary_detector( # noqa: PLR0913 # pylint: disable=too-many-arguments, too-many-locals
1577-
self,
1578-
name: str,
1579-
query: str,
1580-
*,
1581-
group_name: Optional[str] = None,
1582-
confidence_threshold: Optional[float] = None,
1583-
patience_time: Optional[float] = None,
1584-
pipeline_config: Optional[str] = None,
1585-
metadata: Union[dict, str, None] = None,
1586-
) -> Detector:
1587-
"""
1588-
Creates a binary detector with the given name and query.
1589-
1590-
**Example usage**::
1591-
1592-
gl = Groundlight()
1593-
1594-
# Create a binary detector for a door
1595-
detector = gl.create_binary_detector(
1596-
name="door_detector",
1597-
query="Is there a door in the image?",
1598-
confidence_threshold=0.9,
1599-
patience_time=30.0
1600-
)
1601-
1602-
# Use the detector to classify a door
1603-
image_query = gl.ask_ml(detector, "path/to/image.jpg")
1604-
"""
1605-
detector_creation_input = self._prep_create_detector(
1606-
name=name,
1607-
query=query,
1608-
group_name=group_name,
1609-
confidence_threshold=confidence_threshold,
1610-
patience_time=patience_time,
1611-
pipeline_config=pipeline_config,
1612-
metadata=metadata,
1613-
)
1614-
obj = self.detectors_api.create_detector(detector_creation_input, _request_timeout=DEFAULT_REQUEST_TIMEOUT)
1615-
return Detector.parse_obj(obj.to_dict())
1616-
16171576
def create_multiclass_detector( # noqa: PLR0913 # pylint: disable=too-many-arguments, too-many-locals
16181577
self,
16191578
name: str,

0 commit comments

Comments
 (0)