--- title: "Using Vision's Snapshot feature with an External OCR Service" slug: "using-visions-snapshot-feature-with-an-external-ocr-service" tags: ["Vision", "Snapshot", "OCR", "Connector Function"] updated: 2025-01-08T12:24:41Z published: 2025-01-08T12:24:41Z canonical: "support.tulip.co/using-visions-snapshot-feature-with-an-external-ocr-service" --- > ## Documentation Index > Fetch the complete documentation index at: https://support.tulip.co/llms.txt > Use this file to discover all available pages before exploring further. # 외부 OCR 서비스와 함께 Vision의 스냅샷 기능 사용 ## 외부 OCR 서비스와 함께 Vision의 스냅샷 기능 사용 *이미지를 캡처하여 외부 컴퓨터 비전 서비스 API로 보내기* NOTE While you can accomplish this with Vision - another alternative is to use CoPilot. Read more about CoPilot and OCR [here](https://support.tulip.co/docs/extract-text). ## 개요 Vision의 스냅샷 기능은 Tulip 커넥터 및 외부 OCR 서비스와 함께 사용할 수 있습니다. 이 문서에서는 Vision 카메라로 촬영한 스냅샷에서 텍스트를 감지하는 강력한 OCR(광학 문자 인식) 파이프라인을 빠르게 구축하는 방법에 대해 안내합니다. 이 기능을 활용하면 문서를 스캔하거나 인쇄된 라벨의 텍스트, 심지어 물품에 엠보싱 또는 에칭된 텍스트를 읽을 수 있습니다. 다음 문서에서는 Google 비전 OCR로 이 기능을 사용하는 방법을 안내합니다. Google 비전 OCR 기능은 매우 열악한 이미지 조건에서도 텍스트를 판독할 수 있습니다. ### 이 문서에서 안내하는 단계를 따라하세요: 1. 튤립 비전과 Google 클라우드 비전 API 설정하기 2. GCV API에 대한 튤립 커넥터를 만드는 방법 3. 스냅샷을 찍고 OCR 커넥터 기능과 통신하는 앱 빌드하기 ## 전제 조건 ### 카메라 구성과 함께 스냅샷 설정하기 Vision 카메라 구성을 성공적으로 설정했는지 확인하고 Vision의 스냅샷 기능에 익숙해야 합니다. 자세한 내용은 다음을 참조하세요: [Vision 스냅샷 기능 사용하기](https://support.tulip.co/docs/using-visions-snapshot-feature) **구글 클라우드 비전 API 및 구글 클라우드 플랫폼 프로젝트 활성화하기** 이 문서 [(https://cloud.google.com/vision/docs/ocr)](https://cloud.google.com/vision/docs/ocr)에 명시된 지침에 따라 GCP 프로젝트를 만들고 Vision API를 활성화합니다 [.](https://cloud.google.com/vision/docs/ocr) **인증에 사용할 Google Cloud Platform에서 API 키 만들기** [https://cloud.google.com/docs/authentication/api-keys](https://cloud.google.com/docs/authentication/api-keys) 문서에 명시된 지침에 따라 GCP 프로젝트의 API 키를 만듭니다. 이 API 키의 사용을 제한하고 적절한 권한을 설정할 수 있습니다. 이를 구성하는 데 도움이 필요하면 네트워크 관리자에게 문의하세요. ## Google OCR용 튤립 커넥터 함수 만들기 빌드하는 커넥터와 커넥터 함수는 다음 이미지에 명시된 대로 Vision API가 예상하는 요청 유형에 맞게 구성됩니다: ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350109030.png) ### 커넥터 함수 구성하기: 1. HTTP 커넥터를 만듭니다. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350109713.png) 1. Google Vision API 엔드포인트를 가리키도록 커넥터를 구성합니다. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350109975.png) **호스트**: vision.googleapis.com **TLS**: 예3. **콘텐츠 유형을** 포함하도록 연결의 **헤더를** 편집합니다. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350110415.png) 1. 커넥터를**테스트하고** 구성을 **저장합니다**. 2. 다음으로 **POST** 요청 커넥터 함수를 만들고 엔드포인트에 다음 경로를 추가합니다: **v1/images:annotate**. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350110778.png) 1. 커넥터 함수에 **이미지를** 입력으로 추가합니다. 입력 유형이 **텍스트인지** 확인합니다. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350111087.png) 1. 요청 유형이 JSON이고 **요청** **본문이** Google Vision API 요청 유형과 일치하는지 확인합니다: ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_357122749.png) 참고: `PUT_YOUR_API_KEY_HERE를` 위 단계에서 만든 자체 API 키로 바꿉니다.8. 다음으로 텍스트 이미지를 **base64string으로** 변환하여 이 커넥터 기능을 테스트합니다(이를 위해 이 [웹사이트를](https://www.browserling.com/tools/image-to-base64) 사용할 수 있습니다). 이 문자열을 **이미지** 입력 변수의 테스트 값으로 사용합니다. 다음과 유사한 응답이 돌아올 것입니다: ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350111901.png) 1. 출력 변수가**.responses.0.textAnnotations.0.description을** 가리키도록 설정합니다. 2. 커넥터 함수를 저장합니다. ## 스냅샷과 Google OCR 커넥터를 사용하는 튤립 앱 만들기 1. 앱 편집기로 이동하여 스냅샷 트리거를 설정하는 동안 만든 앱을 사용합니다: [스냅샷 기능 사용하기](https://support.tulip.co/docs/using-visions-snapshot-feature) 2. 다음으로 커넥터 기능을 호출하는 트리거가 있는 버튼을 만듭니다. 스냅샷 출력에 저장된 이미지 변수를 커넥터 함수의 입력으로 사용합니다. ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350112339.png) 1. 커넥터 함수에서 반환된 결과를 볼 수 있도록 앱 Step에 변수 **detected_text를** 추가합니다: ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_350112868.png) 1. 앱을 테스트하고 OCR 결과를 관찰합니다: ![](https://cdn.document360.io/7c6ff534-cad3-4fc8-9583-912c4016362f/Images/Documentation/Using%20Vision%27s%20Snapshot%20feature%20with%20an%20External%20OCR%20Service_349150050.png) 이제 구글 비전 API OCR 서비스에 연결되는 툴립 비전 앱을 만들었습니다. 지금 바로 작업 현장에서 사용해 보세요! ## 더 읽어보세요: - [비전 시작하기](https://support.tulip.co/docs/getting-started-with-vision) - [변경 디텍터 사용](https://support.tulip.co/docs/using-the-change-detector) (필요: 인텔 리얼센스 D415) - [지그 디텍터 사용](https://support.tulip.co/docs/using-the-jig-detector) - [컬러 디텍터 사용](https://support.tulip.co/docs/using-the-color-detector) - [앱에서 비전 카메라 위젯 사용](https://support.tulip.co/docs/using-the-vision-camera-widget-in-apps)