Screenshot-to-code开源项目mac上实践

github上的开源项目,看介绍可以将设计ui图片转换为 HTML 和 CSS

源码地址:

GitCode - 开发者的代码家园

我的mac安装了2.7和3.11,就用3吧直接上代码

安装 pip3 install keras tensorflow pillow h5py jupyter

报错

ERROR: Could not install packages due to an OSError: [Errno 13] Permission denied: '/Users/xxx/Library/Python/3.11'

Check the permissions.

mac-xxxdeMacBook-Pro:bin xxx$ sudo pip3 install keras tensorflow pillow h5py jupyter

Password:

WARNING: The directory '/Users/xxx/Library/Caches/pip' or its parent directory is not owned or is not writable by the current user. The cache has been disabled. Check the permissions and owner of that directory. If executing pip with sudo, you should use sudo's -H flag.

解决办法

sudo pip3 install keras tensorflow pillow h5py jupyter

安装好了

tensorboard-data-server-0.7.2 tensorflow-2.15.0 tensorflow-estimator-2.15.0 tensorflow-io-gcs-filesystem-0.35.0 termcolor-2.4.0 terminado-0.18.0 tinycss2-1.2.1 tornado-6.4 traitlets-5.14.0 types-python-dateutil-2.8.19.14 typing-extensions-4.9.0 uri-template-1.3.0 urllib3-2.1.0 wcwidth-0.2.12 webcolors-1.13 webencodings-0.5.1 websocket-client-1.7.0 werkzeug-3.0.1 wheel-0.42.0 widgetsnbextension-4.0.9 wrapt-1.14.1

WARNING: Running pip as the 'root' user can result in broken permissions and conflicting behaviour with the system package manager. It is recommended to use a virtual environment instead: https://pip.pypa.io/warnings/venv

执行运行

jupyter notebook

启动成功

自动打开浏览器,url为http://localhost:8888/tree界面如下图

接下来怎么搞?欢迎评论区讨论

相关推荐
该昵称用户已存在4 分钟前
从单体到微服务・从本地到云端:MyEMS 开源系统的架构演进与落地优势
微服务·架构·开源
发哥来了1 小时前
六款开源大模型中文长文本处理能力横向评测
大数据·人工智能·机器学习·ai·开源·aigc
该昵称用户已存在1 小时前
从能耗报表到碳中和:MyEMS 开源能源管理系统的真实落地样本
开源·能源
梦梦代码精2 小时前
Likeshop一个开源商城到底有哪些功能模块?
java·低代码·开源·php
飞Link2 小时前
2026年大模型落地深度对比:Llama 5 开源权重与 GPT-5 闭源生态
gpt·开源·llama
林小卫很行2 小时前
Obsidian 入门43:给剪藏插件加上 AI,剪藏完自动写摘要、打标签
人工智能·开源
扬帆破浪3 小时前
开源免费的WPS AI 软件 察元AI文档助手:链路 044:脱密对话链路中的 chatCompletion 与 response_format 回退
开源·wps
MapleWan320633 小时前
本地 MCP / Rules / Skills 统一仓库 MSR 可视化管理界面
开源·ai编程
扬帆破浪4 小时前
开源免费的WPS AI 软件 察元AI文档助手:链路 051:assistantPromptRecommendationService 推荐配置
开源·wps
码途漫谈4 小时前
Easy-Vibe高级开发篇阅读笔记(十三)——多平台开发之Android App 原生开发
android·人工智能·笔记·ai·开源·ai编程