Ai Computer Vision user guide
部署服务器后,要在使用“计算机视觉”活动时连接到该服务器,您必须更改“CV 屏幕作用域”和“UiPath 屏幕 OCR”活动的端点。
在活动级别更改端点
在 UiPath Studio 项目的活动级别,您需要更改以下内容:
- the URL property value of the CV Screen Scope activity, and
- the Endpoint property value of the UiPath Screen OCR activity
为 http://[MACHINE_URL]:[PORT],其中 [MACHINE_URL] 是部署服务器的计算机的地址,[PORT] 是设置 Computer Vision 服务器的唯一端口。
例如,如果您的计算机的 URL 是 k80-windows.azure.com,并且您选择使用的端口是 8501,则属性的值应类似于 http://k80-windows.azure.com:8501。
The API key property inside the CV Screen Scope can be left blank for on-premises deployment.
在项目级别更改端点
The default URLs can also be changed from the Project Settings page.
更改 CV 屏幕作用域的端点
To change the endpoint for CV Screen Scope, go to UiPath Studio > your project > Project Settings > Computer Vision > CV Screen Scope > Server > Run value/Debug value > change https://cv.uipath.com to http://[MACHINE_URL]:[PORT], where [MACHINE_URL] is the address of the machine where the server is deployed, and [PORT] is the unique port on which the Computer Vision Server is set up.

更改 UiPath 屏幕 OCR 的端点
To change the endpoint for UiPath Screen OCR, go to UiPath Studio > your project > Project Settings > OCR > UiPath Screen OCR > Endpoint > Run value/Debug value > change https://ocr.uipath.com to http://[MACHINE_URL]:[PORT], where [MACHINE_URL] is the address of the machine where the server is deployed, and [PORT] is the unique port on which the Computer Vision Server is set up.

启用 HTTPS
To encrypt communication, you can add a reverse proxy (for example, NGINX) in front of the container and configure TLS or SSL on this layer.
启用 HTTPS 通信后,您需要将计算机视觉屏幕作用域和 UiPath 屏幕 OCR 的端点从https://cv.uipath.com更改为https://[MACHINE_URL]:[PORT] ,其中[MACHINE_URL]是部署服务器的计算机的地址, [PORT]是部署服务器的计算机地址。设置计算机视觉服务器的唯一端口。
打开默认端口
Make sure you have the port that is used by the Computer Vision activities (default 8501) open on the machine the model is deployed on. For client machines outside of the domain, the DNS is used instead.
要打开服务器计算机上的端口,您必须运行以下控制台命令,将 [PORT] 替换为要使用的实际端口,将 [your-default-zone] 替换为系统的区域(默认情况下为 public):
apt install firewalld
systemctl enable firewalld
firewall-cmd --zone=[your-default-zone] --permanent --add-port=[PORT]/tcp
firewall-cmd --reload
apt install firewalld
systemctl enable firewalld
firewall-cmd --zone=[your-default-zone] --permanent --add-port=[PORT]/tcp
firewall-cmd --reload
更改默认端口
服务器公开的默认端口为 8501。
要更改默认端口,您必须使用其他命令启动服务器。
将 -p 8501:5000 标志更改为 -p [NEW_PORT]:5000,其中 [NEW_PORT] 是要使用的端口。
重新启动服务器
要将端口更改为5000 ,适用于 Linux 的重新启动服务器命令如下所示:
podman run -d
-p 8501:5000
--hooks-dir=/usr/share/containers/oci/hooks.d/ \--security-opt=label=disable --device=nvidia.com/gpu=all
--restart unless-stopped
--name controls_detection
container controls_detection eula=accept
podman run -d
-p 8501:5000
--hooks-dir=/usr/share/containers/oci/hooks.d/ \--security-opt=label=disable --device=nvidia.com/gpu=all
--restart unless-stopped
--name controls_detection
container controls_detection eula=accept