{"id":21562211,"url":"https://github.com/lzxhahaha/nudle","last_synced_at":"2026-03-08T18:37:51.090Z","repository":{"id":19299097,"uuid":"78939680","full_name":"LzxHahaha/nudle","owner":"LzxHahaha","description":"Content base image retrieval platform","archived":false,"fork":false,"pushed_at":"2022-12-06T15:02:37.000Z","size":3734,"stargazers_count":5,"open_issues_count":13,"forks_count":0,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-04-14T19:52:16.772Z","etag":null,"topics":["cbir","cpp","flask","python","react"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/LzxHahaha.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-01-14T12:44:39.000Z","updated_at":"2019-07-25T09:35:23.000Z","dependencies_parsed_at":"2023-01-13T23:30:14.310Z","dependency_job_id":null,"html_url":"https://github.com/LzxHahaha/nudle","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LzxHahaha%2Fnudle","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LzxHahaha%2Fnudle/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LzxHahaha%2Fnudle/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/LzxHahaha%2Fnudle/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/LzxHahaha","download_url":"https://codeload.github.com/LzxHahaha/nudle/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":248217079,"owners_count":21066633,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cbir","cpp","flask","python","react"],"created_at":"2024-11-24T09:31:29.404Z","updated_at":"2026-03-08T18:37:51.049Z","avatar_url":"https://github.com/LzxHahaha.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Content Base Image Retrieval Platform\n\n## DEMO\n\n![demo](./demo.png)\n\n![demo](./demo2.png)\n\n\n## 说明\n\n项目分三个部分：\n\n*   `Saliency`: CPP项目，用于编译出`Saliency RC cut`的动态链接库。代码来源于[CmCode](https://github.com/MingMingCheng/CmCode)\n*   `front`: 前端项目，使用`React.js`实现\n*   `server`: python项目，使用`Flask`与`OpenCV`\n\n## 基本环境安装\n\n\u003e 目前只在Windows下运行过\n\u003e\n\u003e 各个项目的运行方式在各个项目下的`README.md`中查看\n\n### Python\n\n1. 下载并安装[Python 3.6 (64 bit)](https://www.python.org/downloads/)\n2. 在环境变量中新建`PYTHON_DIR`，值为python的安装目录\n3. 在`PATH`中添加`%PYTHON_DIR%`和`%PYTHON_DIR%\\Scripts`\n4. 将`pip`切换到豆瓣源\n5. 使用`pip install \u003cpackage_name\u003e`指令依次安装第三方依赖\n   1. `flask`\n   2. `flask-cors`\n   3. `pymongo`\n   4. `pyparsing`\n6. 以下依赖建议通过`whl`依次进行安装\n   1. [numpy+mkl](http://www.lfd.uci.edu/~gohlke/pythonlibs/#numpy)\n   2. [matplotlib](http://www.lfd.uci.edu/~gohlke/pythonlibs/#matplotlib)\n   3. [scipy](http://www.lfd.uci.edu/~gohlke/pythonlibs/#scipy)\n   4. [scikit-image](http://www.lfd.uci.edu/~gohlke/pythonlibs/#scikit-image)\n   5. [opencv+contrib](http://www.lfd.uci.edu/~gohlke/pythonlibs/#opencv)\n   6. [tornado](http://www.lfd.uci.edu/~gohlke/pythonlibs/#tornado)\n   7. [pycurl](http://www.lfd.uci.edu/~gohlke/pythonlibs/#pycurl)\n\n\u003e 建议版本为[requirement.txt](./server/requirements.txt)中的版本或更高\n\n### OpenCV\n\n1. 下载并解压[OpenCV 3.2](https://sourceforge.net/projects/opencvlibrary/)\n2. 在环境变量中新建`OPENCV_DIR`，值为OpenCV解压的目录\n3. 在`PATH`中添加`%OPENCV_DIR%\\build\\x64\\vc14\\bin`\n\n### Boost\n\n1. 安装`Visual Studio 2015`\n2. 下载并解压[Boost 1.63.0](https://sourceforge.net/projects/boost/files/boost/1.63.0/)\n3. 用VS自带的`VS2015 x64 本机工具命令提示符`编译Boost\n```\n$ cd /d \u003cBoost dir\u003e\n$ bootstrap.bat\n```\n4. 用文本编辑器打开生成的`project-config.jam`，在末尾添加\n```\nusing python : 3.6 : \u003cPython dir\u003e : \u003cPython dir\u003e/include : \u003cPython dir\u003e/libs ;\n```\n5. 开始编译Boost\n```\n$ bjam.exe toolset=msvc-14.0 address-model=64 --prefix=\u003cBoost dir\u003e/build --build-type=complete --with-python install\n```\n6. 将生成的`build/lib`文件夹移动到`\u003cBoost dir\u003e/lib`，之后可以删除`build`文件夹以及上一步生成的`bin.v2`文件夹\n7. 在环境变量中新建`BOOST_DIR`，值为Boost解压的目录\n8. 在`PATH`中添加`%BOOST_DIR%`和`%BOOST_DIR%\\lib`\n\n### MongoDB\n\n1. 下载并安装[MongoDB](https://www.mongodb.com/download-center#community)\n1. 安装MongoDB服务\n```\nmongod --dbpath \u003cMongoDB data path\u003e --logpath \u003cMongoDB data path\u003e\\mongo.log --logappend --serviceName MongoDB --serviceDisplayName MongoDB  --install\n```\n其中的`\u003cMongoDB data path\u003e`为自定的路径，用于存放数据以及log\n\n### Node.js\n\n1. 下载并安装[Node.js 最新版本](https://nodejs.org/en/download/)\n2. 执行以下命令\n```\n$ npm config set registry https://registry.npm.taobao.org \n$ npm i -g babel-core babel-cli yarn webpack webpack-dev-server\n```\n\n### Nginx（可选）\n\n1. 下载并安装[Nginx](http://nginx.org/en/download.html)\n1. 打开`\u003cNginx path\u003e/conf/nginx.conf`，修改配置\n```\nserver {\n    listen 80;                                      # 可修改为其他端口     \n    server_name cbir;\n    charset utf-8;\n    \n    location ~* /static/.+\\.(jpe?g|png|ico)$ {\n        alias   \u003cServer code path\u003e/static;          # 静态图片路径\n        gzip    on;\n        expires 30d;\n    }\n    \n    location ~* /static/.+\\.js$ {\n        alias   \u003cServer code path\u003e/static;          # 脚本文件路径\n        gzip    on;\n        expires 7d;\n    }\n\n    location / {\n        proxy_pass http://localhost:\u003cPython port\u003e;           # Python port 为自定端口，默认5000\n        proxy_set_header X-Real-IP $remote_addr;\n        proxy_pass_header Set-Cookie;\n    }\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flzxhahaha%2Fnudle","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flzxhahaha%2Fnudle","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flzxhahaha%2Fnudle/lists"}