이미지에서 객체의 좌표 얻기
이미지 본문과 영어로 된 코멘트를 게시하고 지정된 개체의 좌표를 최대 6세트까지 받아보세요. 사각형 좌표뿐만 아니라 점 좌표도 요청할 수 있습니다. 한 면의 최대 이미지 크기는 500픽셀입니다. 그보다 큰 이미지는 작업자 인터페이스에서 축소됩니다.
'점' 및 '직사각형' 작업의 예시
태스크 객체
프로퍼티 | 유형 | 필수 | 목적 |
---|---|---|---|
type | 스트링 | 예 | ImageToCoordinatesTask 태스크 유형을 규정하세요. |
body | 스트링 | 예 | 파일 본문 base64로 인코딩됨. 줄바꿈 없이 전송하세요. 'data:image/png,' 혹은 유사한 태그를 포함하지 마세요. 말끔한 base64만 이용하세요! |
comment | 스트링 | 아니요 | 영어 문자로만 작업에 대한 설명을 입력합니다. 예시: "Select objects in specified order" 또는 "select all cars". |
mode | 스트링 | 아니요 | 작업 모드는 "points" 또는 "rectangles"일 수 있습니다. 기본값은 "points"입니다. |
websiteURL | 스트링 | 아니요 | 지출 통계에서 이미지 캡챠의 출처를 구분하는 선택적인 매개변수 |
예시 요청
Python
Javascript
PHP
bash
#pip3 install anticaptchaofficial
from anticaptchaofficial.imagetocoordinates import *
solver = imagetocoordinates()
solver.set_verbose(1)
solver.set_key("YOUR_KEY")
solver.set_mode("points")
solver.set_comment("Select objects in specified order")
coordinates = solver.solve_and_return_solution("coordinates.png")
if coordinates != 0:
print("coordinates: ", coordinates)
else:
print("task finished with error "+solver.error_code)
태스크 솔루션 객체
프로퍼티 | 유형 | 목적 |
---|---|---|
coordinates | 스트링 | 좌표 집합의 배열입니다. "points" 모드의 경우 (x,y) 집합입니다. '직사각형'의 경우 왼쪽 상단에서 오른쪽 하단으로 시작하여 (x1,y1,x2,y2)입니다. 좌표 시작점은 왼쪽 상단 모서리입니다. |
반응 예시
{
"errorId":0,
"status":"ready",
"solution":
{
"coordinates":[
[17,48,54,83],
[76,93,140,164]
]
},
"cost":"0.000700",
"ip":"46.98.54.221",
"createTime":1472205564,
"endTime":1472205570,
"solveCount":"0"
}