Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/unarxiv/CVPM into bug/run…
Browse files Browse the repository at this point in the history
…ning-port#5
  • Loading branch information
xzyaoi committed Oct 18, 2018
2 parents 0e793db + 2a6f1a9 commit df24cfe
Show file tree
Hide file tree
Showing 16 changed files with 11,240 additions and 22 deletions.
14 changes: 7 additions & 7 deletions dashboard/package.json
Expand Up @@ -16,10 +16,10 @@
"dependencies": {
"vue": "2.5.17",
"vue-router": "3.0.1",
"vuetify": "1.2.9"
"vuetify": "1.3.0"
},
"devDependencies": {
"autoprefixer": "9.1.5",
"autoprefixer": "9.2.0",
"babel-core": "6.26.3",
"babel-eslint": "10.0.1",
"babel-helper-vue-jsx-merge-props": "2.0.3",
Expand All @@ -34,7 +34,7 @@
"babel-preset-stage-2": "6.24.1",
"babel-register": "6.26.0",
"chalk": "2.4.1",
"chromedriver": "2.42.0",
"chromedriver": "2.43.0",
"copy-webpack-plugin": "4.5.3",
"cross-spawn": "6.0.5",
"css-loader": "1.0.0",
Expand All @@ -57,7 +57,7 @@
"node-notifier": "5.2.1",
"optimize-css-assets-webpack-plugin": "5.0.1",
"ora": "3.0.0",
"portfinder": "1.0.17",
"portfinder": "1.0.18",
"postcss-import": "12.0.0",
"postcss-loader": "3.0.0",
"postcss-url": "8.0.0",
Expand All @@ -67,12 +67,12 @@
"shelljs": "0.8.2",
"uglifyjs-webpack-plugin": "2.0.1",
"url-loader": "1.1.2",
"vue-jest": "2.6.0",
"vue-jest": "3.0.0",
"vue-loader": "15.4.2",
"vue-style-loader": "4.1.2",
"vue-template-compiler": "2.5.17",
"webpack": "4.20.2",
"webpack-bundle-analyzer": "3.0.2",
"webpack": "4.21.0",
"webpack-bundle-analyzer": "3.0.3",
"webpack-dev-server": "3.1.9",
"webpack-merge": "4.1.4"
},
Expand Down
4 changes: 4 additions & 0 deletions docs/.vuepress/config.js
Expand Up @@ -110,6 +110,10 @@ module.exports = {
children: [
'',
'getting-started',
'install-package',
'write-package',
'contributing',
'credits'
]
}
]
Expand Down
12 changes: 6 additions & 6 deletions docs/README.md
Expand Up @@ -4,24 +4,24 @@ heroImage: /logo.png
actionText: Get Started →
actionLink: /en-US/guide/
features:
- title: User Friendly
details: It is smaller and less complex than some other computer vision libraries. It provide an easy-to-use user interface to interacts with.
- title: Developer Friendly
- title: Reproducible
details: Install pre-trained models along with the source code.
- title: Security
details: Enjoy the dev experience of developing with CVTron. Adopting it to your own product is very soon and easy. Join our community will bring you more fun to develop with.
- title: Commercial Ready
- title: Authorizable
details: Feel free to use it in your commercial product. Some companies have tested it in production environment already. We are also providing consulting service.
footer: MIT Licensed | Copyright © 2018-Present UnArxiv Foundation
---
### As Easy as 1, 2, 3

``` bash
# install
curl xxx # OR npm install -g vuepress
curl https://get.autoai.org/cvpm/latest.sh # OR manually download binary

# Download Computer Vision Package
cvpm install xzyaoi/Face_Utility # OR cvpm install https://github.com/xzyaoi/Face_Utility

# start writing
# start serving
cvpm repo run xzyaoi/Face_Utility/Face_Detection
```

Expand Down
27 changes: 25 additions & 2 deletions docs/en-US/guide/README.md
@@ -1,3 +1,26 @@
# Introduction
# CVPM Introduction

# Welcome
[![Go Report Card](https://goreportcard.com/badge/github.com/unarxiv/cvpm)](https://goreportcard.com/report/github.com/unarxiv/cvpm)
[![Build Status](https://travis-ci.org/unarxiv/CVPM.svg?branch=master)](https://travis-ci.org/unarxiv/CVPM)
[![GitHub issues](https://img.shields.io/github/issues/unarxiv/cvpm.svg?style=flat-square)](https://github.com/unarxiv/cvpm/issues)
[![GitHub license](https://img.shields.io/github/license/unarxiv/cvpm.svg?style=flat-square)](https://github.com/unarxiv/CVPM/blob/master/LICENSE)

## Introduction

CVPM is a package manager for computer vision. It helps you to download, install and run a computer vision service.

[![asciicast](https://asciinema.org/a/YRgOSy1a7WwdPyK77PEgE12Kl.png)](https://asciinema.org/a/YRgOSy1a7WwdPyK77PEgE12Kl)

## Contributing

If you found a security bugs, please do not post it in issues or any other public forum. You can send me [email](mailto:xiaozhe.yaoi@qq.com) directly.

## Affiliated Project

This project is inspired from [CVTron](https://docs.cvtron.org).

## FAQs

Q: Where can I find useful models?

A: There are three places. The first one, which is we recommend most, is our [model hub](https://hub.autoai.org), where you can download, purchase, search models. The second one is GitHub, in GiHub, you can search for CVPM_Available in readme file, which indicates that repository is compatible with CVPM. The third one is our [forum](https://forum.cvtron.xyz), where you can discuss performance of models, and ask for others models.
1 change: 1 addition & 0 deletions docs/en-US/guide/contributing.md
@@ -0,0 +1 @@
# Contribute
11 changes: 11 additions & 0 deletions docs/en-US/guide/credits.md
@@ -0,0 +1,11 @@
# Credit

We would like to extend our sincere appreciate for the following organizations and individuals for their kind help during the development and production of CVPM.

* [Shenzhen University](https://www.szu.edu.cn) for providing lots of general help.
* [Oregon State University Open Source Lab](https://www.google.com.hk/search?q=osuosl&oq=osusl&aqs=chrome.1.69i57j0l5.2563j1j4&sourceid=chrome&ie=UTF-8) for hosting open source and public models.
* [Netlify](https://www.netlify.com/) for providing CI/CD for documentation.
* [Clarifai](https://clarifai.com/) for providing image recognition models.
* [Amazon Web Services](https://aws.amazon.com) for providing general web services.

During the development, we are standing on the shoulders of many open source software listed below but not limited to.
11 changes: 10 additions & 1 deletion docs/en-US/guide/getting-started.md
Expand Up @@ -33,4 +33,13 @@ Or, RUN ```cvpm install https://github.com/vendor/repo``` to install a package f
Before you run any of your installed repo, a daemon process must be enabled. Note that you only need to enable it once by running
```cvpm daemon install```. It may requires you administrator permission to install on most systems.

Some repos may have more than one solver in it, therefore, you have to know the exact solver name to run. By running ```cvpm run vendor/repo/solver```, you can start a service.
Some repos may have more than one solver in it, therefore, you have to know the exact solver name to run. By running ```cvpm run vendor/repo/solver port```, you can start a service.

### Example

For example, we have an official model named Face_Utility with three solvers. If you want to run a face detection solver, after your installation, simply do as following:

```
cvpm install https://github.com/cvmodel/Face_Utility
cvpm repo run cvmodel/Face_Utility/Face_Detection 8080
```
2 changes: 2 additions & 0 deletions docs/en-US/guide/install-package.md
@@ -0,0 +1,2 @@
# Install a Package

73 changes: 73 additions & 0 deletions docs/en-US/guide/write-package.md
@@ -0,0 +1,73 @@
# Write a Package

## Prepare Your Model Locally

### Project Structure

Your package is firstly a Python Package. Therefore, it will look like:

```
- example_package
- example_package
- solver.py
- bundle.py
- pretrained
- pretrained.toml
- tests // optional
- examples // optional
- cvpm.toml
- requirements.txt
- README.md
```

### Solvers

Solver is a ```class``` extended from ```cvpm.Solver``` class. In this class, you need to implement 2 functions: ```__init__``` and ```infer```. As their literal meanings, in the ```init``` function, parameters that your infer functions use should be initiate, and in the ```infer``` function, a image file path will be passed in the parameter, and the ```infer``` function is supposed to return your result in a dict or list.

For example, a simple solver frame will look like

``` python
from cvpm.solver import Solver

class SampleSolver(Solver):
def __init__(self, toml_file=None):
super().__init__(toml_file)
# Do you Init Work here
self.classifer = get_classifier()
self.set_ready()
def infer(self, image_file, config):
# Use your own load_image method, or from cvpm.utility import load_image_file
image = load_image(image_file)
result = self.classifier(image)
return result
```

### Bundle

::: tip
This chapter and its related function may have broken changes recently. ([#64](https://github.com/unarxiv/CVPM/issues/64))
:::



### cvpm.toml

### Pre-trained models

## Publish to Model Hub

## Publish to GitHub

When publishing to GitHub, mention "CVPM Available" at the top of your README file, only if you want you model to be searchable by the Model Hub.

Your README file should be look like

```
## PROJECT NAME
[CVPM-Available](https://hub.autoai.org)
```

You can look at [Face Utility](https://github.com/cvmodel/Face_Utility) for reference that we provided as an official repository.

## Best Practice
27 changes: 25 additions & 2 deletions docs/zh-CN/guide/README.md
@@ -1,3 +1,26 @@
# Introduction
# CVPM Introduction

# Welcome
[![Go Report Card](https://goreportcard.com/badge/github.com/unarxiv/cvpm)](https://goreportcard.com/report/github.com/unarxiv/cvpm)
[![Build Status](https://travis-ci.org/unarxiv/CVPM.svg?branch=master)](https://travis-ci.org/unarxiv/CVPM)
[![GitHub issues](https://img.shields.io/github/issues/unarxiv/cvpm.svg?style=flat-square)](https://github.com/unarxiv/cvpm/issues)
[![GitHub license](https://img.shields.io/github/license/unarxiv/cvpm.svg?style=flat-square)](https://github.com/unarxiv/CVPM/blob/master/LICENSE)

## Introduction

CVPM is a package manager for computer vision. It helps you to download, install and run a computer vision service.

[![asciicast](https://asciinema.org/a/YRgOSy1a7WwdPyK77PEgE12Kl.png)](https://asciinema.org/a/YRgOSy1a7WwdPyK77PEgE12Kl)

## Contributing

If you found a security bugs, please do not post it in issues or any other public forum. You can send me [email](mailto:xiaozhe.yaoi@qq.com) directly.

## Affiliated Project

This project is inspired from [CVTron](https://docs.cvtron.org).

## FAQs

Q: Where can I find useful models?

A: There are three places. The first one, which is we recommend most, is our [model hub](https://hub.autoai.org), where you can download, purchase, search models. The second one is GitHub, in GiHub, you can search for CVPM_Available in readme file, which indicates that repository is compatible with CVPM. The third one is our [forum](https://forum.cvtron.xyz), where you can discuss performance of models, and ask for others models.
1 change: 1 addition & 0 deletions docs/zh-CN/guide/contributing.md
@@ -0,0 +1 @@
# 参与
1 change: 1 addition & 0 deletions docs/zh-CN/guide/credits.md
@@ -0,0 +1 @@
# 致谢
1 change: 1 addition & 0 deletions docs/zh-CN/guide/install-package.md
@@ -0,0 +1 @@
# 安装及运行
1 change: 1 addition & 0 deletions docs/zh-CN/guide/write-package.md
@@ -0,0 +1 @@
# 创建新的包

0 comments on commit df24cfe

Please sign in to comment.