<Additional information about your API call. Try to use verbs that match both request type (fetching vs modifying) and plurality (one vs multiple).>
-
URL
<The URL Structure (path only, no root url)>
-
Method:
| //Ejemplo sencillo para poder manejar un motor servo conectado aun ardunio desde nodejs | |
| //app.js fichero principal tipo express | |
| var express = require('express'); | |
| //npm install serialport | |
| //https://github.com/voodootikigod/node-serialport | |
| var serialport = require("serialport"); | |
| var SerialPort = serialport.SerialPort; // localize object constructor | |
| var app = module.exports = express.createServer(); |
| import numpy as np | |
| def gs_cofficient(v1, v2): | |
| return np.dot(v2, v1) / np.dot(v1, v1) | |
| def multiply(cofficient, v): | |
| return map((lambda x : x * cofficient), v) | |
| def proj(v1, v2): | |
| return multiply(gs_cofficient(v1, v2) , v1) |
| import numpy as np | |
| def GENP(A, b): | |
| ''' | |
| Gaussian elimination with no pivoting. | |
| % input: A is an n x n nonsingular matrix | |
| % b is an n x 1 vector | |
| % output: x is the solution of Ax=b. | |
| % post-condition: A and b have been modified. | |
| ''' |
| class FilterMixin(object): | |
| """ | |
| View mixin which provides filtering for ListView. | |
| """ | |
| filter_url_kwarg = 'filter' | |
| default_filter_param = None | |
| def get_default_filter_param(self): | |
| if self.default_filter_param is None: | |
| raise ImproperlyConfigured( |
| // RGB to CMYK conversion | |
| void rgb2cmyk(cv::Mat& img, std::vector<cv::Mat>& cmyk) { | |
| // Allocate cmyk to store 4 componets | |
| for (int i = 0; i < 4; i++) { | |
| cmyk.push_back(cv::Mat(img.size(), CV_8UC1)); | |
| } | |
| // Get rgb | |
| std::vector<cv::Mat> rgb; | |
| cv::split(img, rgb); |
Pequeña guía de estilo para código Python
Examples shown are bare minimum needed to achieve a simple goal.
c-c-c-c-c-ULTIMATE c-c-c-COMBO!!!This guide assumes you have the emmet and language-babel packages already installed in Atom
keymap.cson file by clicking on Atom -> Keymap… in the menu bar'atom-text-editor[data-grammar~="jsx"]:not([mini])':