Add Docker support for running onnx-modifier#146
Open
helloworld77 wants to merge 8 commits into
Open
Conversation
Major UI/UX improvements: - Unified button styling across all components with consistent neutral colors - Redesigned toolbar buttons: 1.83x larger (44x44px) with professional styling - Horizontal toolbar layout with proper spacing and alignment - Added theme toggle button to toolbar with sun/moon icons Technical changes: - Standardized fonts to system font stack across all components - Fixed Node Properties alignment (removed extra left spacing) - Added null checks for removed DOM elements (shapeInference, cleanUp, addNode) - Enhanced dark theme support for all new components - Improved button hover effects with smooth animations - Added flex spacer to position Back/Name buttons at toolbar end
feat: Redesign UI with modern styling and improved UX
…ovement Revert "feat: Redesign UI with modern styling and improved UX"
Owner
|
@helloworld77 Thanks for the contribution. What are the necessities of the modifications in |
Author
"Sorry for the late reply. The modifications in static/index.js and flask_server.py enable a direct browser-side download feature. Currently, the tool saves modified models into a predefined folder on the server. With these changes, users can now download the modified model directly through their browser as a standard file download, which is more flexible for remote deployments." |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Summary
This PR adds the ability to run onnx-modifier in a Docker container, so users can start the service without installing Python or dependencies locally. The documentation in README is updated with a new section "launch from Docker container".
Motivation
Changes
Dockerfile(new)requirements.txt.python entry.py --host 0.0.0.0 --port 5000so the app is reachable from outside the container.README.mddocker buildanddocker runcommands.http://0.0.0.0:5000/andhttp://127.0.0.1:5000/; opening either in the browser launches onnx-modifier.onnx_modifier/flask_server.pyentry.py(or the script that starts the server) is assumed to support--hostand--portso the server can bind to0.0.0.0:5000inside the container. Any small changes in this file are to support that and/or fix download behavior when running in Docker (e.g. using absolute path forsend_fileif needed). Models can now download directly through the browser as a standard file.How to use (for reviewers/users)
Then open
http://127.0.0.1:5000/(orhttp://0.0.0.0:5000/) in a browser.Note for maintainers
python:3.9-slimandpip installcan be run without a custom index (e.g. remove-i https://pypi.tuna.tsinghua.edu.cn/simplefor a generic Dockerfile).修改说明
主要特征:支持通过 Docker 容器启动 onnx-modifier
简述
本 PR 增加通过 Docker 运行 onnx-modifier 的方式,并在 README 中新增「launch from Docker container」小节,包含构建与运行命令。使用方式与从源码启动一致:构建镜像 → 运行容器 → 在浏览器中打开输出的地址即可使用。
主要修改
requirements.txt,默认以--host 0.0.0.0 --port 5000启动,便于从宿主机访问。http://0.0.0.0:5000/或http://127.0.0.1:5000/。--host/--port并在容器内正确绑定;如有需要,修正下载逻辑(如使用绝对路径)以在 Docker 环境下正常工作。修改static/index.js 和 flask_server.py,支持浏览器直接下载修改后的模型作为标准文件(同时保留原有的存储到指定目录)。使用步骤
见上方英文版中的
docker build与docker run命令,启动后在浏览器打开http://127.0.0.1:5000/即可。