当前位置: 首页 > wzjs >正文

番禺网站建设制作可以做公众号的网站吗

番禺网站建设制作,可以做公众号的网站吗,多行业品牌企业公司网站模板,推广平台软件安装python环境 我这里是以前安装好的版本:python 3.11.5,这里不再介绍,有需要的可以在网上找教程。 安装Anaconda 我这里是以前安装好的版本:conda 23.7.4,这里也不再介绍,有需要的可以在网上找教程。 …

安装python环境

我这里是以前安装好的版本:python 3.11.5,这里不再介绍,有需要的可以在网上找教程。

安装Anaconda

我这里是以前安装好的版本:conda 23.7.4,这里也不再介绍,有需要的可以在网上找教程。

安装OmniParser

git clone https://github.com/microsoft/OmniParser.git
cd OmniParser

创建专属环境

conda create -n "omni" python==3.11
conda activate omni

执行下面命令,下载所需要的依赖包。

pip install -r requirements.txt

下载 microsoft/OmniParser-v2.0 模型文件,但是一直进不去网址(https://huggingface.co),所以我选择了https://hf-mirror.com/。

在这里插入图片描述

找到microsoft/OmniParser-v2.0

在这里插入图片描述

进去之后点击icon_caption和icon_detect)文件夹,分别下载里面文件。

在这里插入图片描述

主要为下面6个文件。

icon_detect/train_args.yaml
icon_detect/model.pt
icon_detect/model.yaml
icon_caption/config.json
icon_caption/generation_config.json
icon_caption/model.safetensors

在项目目录下新建目录,具体如下

mkdir -p weights/icon_detect
mkdir -p weights/icon_caption_florence

完成效果如下:

在这里插入图片描述

将前面下载好的文件分别对应的文件夹。

在这里插入图片描述

运行 python gradio_demo.py 命令,稍等之后出现如下面报错。

[2025-02-25 20:11:26,669] [ WARNING] easyocr.py:80 - Neither CUDA nor MPS are available - defaulting to CPU. Note: This module is much faster with a GPU.
Traceback (most recent call last):File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connection.py", line 203, in _new_connsock = connection.create_connection(^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\util\connection.py", line 85, in create_connectionraise errFile "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\util\connection.py", line 73, in create_connectionsock.connect(sa)
TimeoutError: timed outThe above exception was the direct cause of the following exception:Traceback (most recent call last):File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connectionpool.py", line 790, in urlopenresponse = self._make_request(^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connectionpool.py", line 491, in _make_requestraise new_eFile "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connectionpool.py", line 467, in _make_requestself._validate_conn(conn)File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connectionpool.py", line 1096, in _validate_connconn.connect()File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connection.py", line 611, in connectself.sock = sock = self._new_conn()^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connection.py", line 212, in _new_connraise ConnectTimeoutError(
urllib3.exceptions.ConnectTimeoutError: (<urllib3.connection.HTTPSConnection object at 0x0000019B3B7505D0>, 'Connection to huggingface.co timed out. (connect timeout=10)')The above exception was the direct cause of the following exception:Traceback (most recent call last):File "D:\DevelopmentTools\Python\Lib\site-packages\requests\adapters.py", line 486, in sendresp = conn.urlopen(^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\connectionpool.py", line 844, in urlopenretries = retries.increment(^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\urllib3\util\retry.py", line 515, in incrementraise MaxRetryError(_pool, url, reason) from reason  # type: ignore[arg-type]^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='huggingface.co', port=443): Max retries exceeded with url: /microsoft/Florence-2-base/resolve/main/config.json (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x0000019B3B7505D0>, 'Connection to huggingface.co timed out. (connect timeout=10)'))During handling of the above exception, another exception occurred:Traceback (most recent call last):File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 1376, in _get_metadata_or_catch_errormetadata = get_hf_file_metadata(^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\utils\_validators.py", line 114, in _inner_fnreturn fn(*args, **kwargs)^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 1296, in get_hf_file_metadatar = _request_wrapper(^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 280, in _request_wrapperresponse = _request_wrapper(^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 303, in _request_wrapperresponse = get_session().request(method=method, url=url, **params)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\requests\sessions.py", line 589, in requestresp = self.send(prep, **send_kwargs)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\requests\sessions.py", line 703, in sendr = adapter.send(request, **kwargs)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\utils\_http.py", line 96, in sendreturn super().send(request, *args, **kwargs)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\requests\adapters.py", line 507, in sendraise ConnectTimeout(e, request=request)
requests.exceptions.ConnectTimeout: (MaxRetryError("HTTPSConnectionPool(host='huggingface.co', port=443): Max retries exceeded with url: /microsoft/Florence-2-base/resolve/main/config.json (Caused by ConnectTimeoutError(<urllib3.connection.HTTPSConnection object at 0x0000019B3B7505D0>, 'Connection to huggingface.co timed out. (connect timeout=10)'))"), '(Request ID: 3ae795ae-e87f-45e3-8c1b-26c359494139)')The above exception was the direct cause of the following exception:Traceback (most recent call last):File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\utils\hub.py", line 342, in cached_fileresolved_file = hf_hub_download(^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\utils\_validators.py", line 114, in _inner_fnreturn fn(*args, **kwargs)^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 862, in hf_hub_downloadreturn _hf_hub_download_to_cache_dir(^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 969, in _hf_hub_download_to_cache_dir_raise_on_head_call_error(head_call_error, force_download, local_files_only)File "D:\DevelopmentTools\Python\Lib\site-packages\huggingface_hub\file_download.py", line 1489, in _raise_on_head_call_errorraise LocalEntryNotFoundError(
huggingface_hub.errors.LocalEntryNotFoundError: An error happened while trying to locate the file on the Hub and we cannot find the requested files in the local cache. Please check your connection and try again or make sure your Internet connection is on.The above exception was the direct cause of the following exception:Traceback (most recent call last):File "E:\OmniParser\gradio_demo.py", line 16, in <module>caption_model_processor = get_caption_model_processor(model_name="florence2", model_name_or_path="weights/icon_caption_florence")^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "E:\OmniParser\util\utils.py", line 63, in get_caption_model_processorprocessor = AutoProcessor.from_pretrained("microsoft/Florence-2-base", trust_remote_code=True)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\models\auto\processing_auto.py", line 305, in from_pretrainedconfig = AutoConfig.from_pretrained(^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\models\auto\configuration_auto.py", line 1075, in from_pretrainedconfig_dict, unused_kwargs = PretrainedConfig.get_config_dict(pretrained_model_name_or_path, **kwargs)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\configuration_utils.py", line 594, in get_config_dictconfig_dict, kwargs = cls._get_config_dict(pretrained_model_name_or_path, **kwargs)^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\configuration_utils.py", line 653, in _get_config_dictresolved_config_file = cached_file(^^^^^^^^^^^^File "D:\DevelopmentTools\Python\Lib\site-packages\transformers\utils\hub.py", line 385, in cached_fileraise EnvironmentError(
OSError: We couldn't connect to 'https://huggingface.co' to load this file, couldn't find it in the cached files and it looks like microsoft/Florence-2-base is not the path to a directory containing a file named config.json.
Checkout your internet connection or see how to run the library in offline mode at 'https://huggingface.co/docs/transformers/installation#offline-mode'.

看着错误很多,其实就是 https://huggingface.co 访问不到的原因。我们将constants.py文件里的 https://huggingface.co 替换为https://hf-mirror.com。

在这里插入图片描述

为此,还是不放心,网上找了教程,又在最前面加了一行设置。

在这里插入图片描述

再次输入 python gradio_demo.py 命令,运行成功如下图所示:

在这里插入图片描述

在浏览器输入:http://127.0.0.1:7861,显示结果如下:

在这里插入图片描述

截一张桌面的图,让他进行分析:

在这里插入图片描述
END

毋庸置疑,好的事情总会到来。而当它来晚时,也不失为一种惊喜。


文章转载自:

http://xrPRFVaX.nrqtk.cn
http://XBwEaZxH.nrqtk.cn
http://lUjApZNZ.nrqtk.cn
http://vcIYdFDG.nrqtk.cn
http://uYh0APHC.nrqtk.cn
http://6IuH9CLy.nrqtk.cn
http://GjK2OkkI.nrqtk.cn
http://B0hg6Pm9.nrqtk.cn
http://FdRBFEMg.nrqtk.cn
http://e1vxx0Ak.nrqtk.cn
http://1ykESJId.nrqtk.cn
http://vJeSBwTf.nrqtk.cn
http://uhWOXCLC.nrqtk.cn
http://vyXgnkg1.nrqtk.cn
http://GxbgIgjE.nrqtk.cn
http://1ckBBoBc.nrqtk.cn
http://oLYmm0yP.nrqtk.cn
http://eMmZwH4P.nrqtk.cn
http://2QPZxbWs.nrqtk.cn
http://khY1Lmi9.nrqtk.cn
http://BKLg6h5c.nrqtk.cn
http://ZhRYbet9.nrqtk.cn
http://xvVMieBM.nrqtk.cn
http://8R19sRFJ.nrqtk.cn
http://votJRH6o.nrqtk.cn
http://bo237OOa.nrqtk.cn
http://7XklYbRx.nrqtk.cn
http://ItjBAjEJ.nrqtk.cn
http://svcCk3F6.nrqtk.cn
http://HqKaYShB.nrqtk.cn
http://www.dtcms.com/wzjs/618341.html

相关文章:

  • 辽宁省和城乡建设厅网站两学一做 网站
  • 科普网站栏目建设方案策划网页站点不安全
  • 泸西县住房和城乡建设局网站免费网站建设找哪家
  • 兰州网站建设慕枫商城网站风格
  • 免费搭建个人博客网站wordpress react 影响
  • 史志网站建设wordpress 敏感词过滤
  • 教育云平台网站建设wordpress插件 数据库
  • 网站建设工种河南住房和城乡建设部网站首页
  • 如何让新网站被收录精品网站欣赏
  • 公司改名网站备案网页设计实训班
  • js 网站怎么做中英文竞价网站与竞价网站之间做友情链接
  • 哪些网站可以做详情页建立手机网站
  • 建设部网站退休注册人员办公室局域网怎么搭建
  • 海南省建设注册中心网站黑帽友情链接
  • 做国际贸易哪个网站比较好福田建网站多少钱
  • 为什么要建设档案网站网站建设如何赚钱
  • 织梦网站栏目访问目录wordpress新增管理员
  • word68网站浙江网站建设抖音seo优化
  • 做百度推广送的网站wordpress 如何安装中文版本
  • 济南网站制作案例做网站九州科技
  • 我要做网站做网站临泉做淘宝客网站一定要备案吗
  • 在县城做团购网站网牛网站建设
  • 嘉兴做网站公司哪家好wordpress cdn图片加速
  • 做查询网站 发布数据wordpress 异步加速
  • 网站源码推荐域名价值
  • 网站的推广运营开发app的短信费用多少
  • 做感恩网站的图片asp.net网站恢复
  • 网站后台管理系统数据库十大网站建立公司
  • 给网站挂黑链七牛云做网站
  • 公司网站建设方案详细方案大学生做网站类型