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
from django.conf.urls import url | |
from rest_framework.urlpatterns import format_suffix_patterns | |
from connection import views | |
urlpatterns = [ | |
url(r'^connection/$', views.CodeList), | |
url(r'^connection/(?P<pk>[0-9]+)/$', views.CodeDetail), | |
] | |
urlpatterns = format_suffix_patterns(urlpatterns) |
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
class ListArray { | |
private: | |
const MAX_SIZE; | |
public: | |
void other_methods; | |
}; | |
ListArray::ListArray(){ | |
MAX_SIZE = 10; | |
//da erro aqui. |
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
# Cross-compiler | |
CC = g++ | |
# C building settings | |
CFLAGS = -O2 -ansi -Wall | |
# C++ source and object files | |
C_DIR = src | |
C_SRC = $(wildcard $(C_DIR)/*.cpp) | |
C_OBJ = $(C_SRC:$(C_DIR)/%.cpp=$(OBJ_DIR)/%.o) |
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
void PointClickDistance::draw_grid(cv::Mat frame){ | |
for(int i = 0; i <= 640; i +=160){ | |
cv::line(frame, cv::Point(i, 0), cv::Point(i, 480), cv::Scalar(255, 0, 0)); | |
for(int j = 0; j < 480; j += 120) | |
cv::line(frame, cv::Point(0, j), cv::Point(640, j), cv::Scalar(255, 0, 0)); | |
} | |
} |
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
void initializeGLCM(int* glcmMat); | |
int main(int argc, char const *argv[]) | |
{ | |
cv::Mat inputImg = cv::imread(argv[1]); | |
int glcmMat[256][256]; | |
cv::cvtColor(inputImg, inputImg, CV_BGR2GRAY); |
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
cv::Mat glcm(256, 256, CV_8UC1); | |
int glcmMat[256][256]; | |
for (int i = 0; i < inputImg.rows - 1; ++i) | |
for (int j = 0; j < inputImg.cols - 1; ++j) | |
glcmMat[(int)inputImg.at<uchar>(i,j)][(int)inputImg.at<uchar>(i, j+1)]++; | |
for (int i = 0; i < 256; ++i) | |
for (int j = 0; j < 256; ++j) | |
glcm.at<uchar>(i,j) = (uchar)glcmMat[i][j]; |
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
#include <stdio.h> | |
int main(int argc, char const *argv[]) | |
{ | |
int right = 0, up = 0; | |
int input; | |
do | |
{ |
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
import datetime | |
print(datetime.datetime.now().strftime("%H-%M")) |
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
from datetime import datetime, timedelta | |
lasttime = datetime.now() | |
#you're gonna save your previous date like this ^ | |
tomorrow = lasttime + timedelta(days=1) | |
now = datetime.now() | |
if tomorrow <= now: | |
print('is already tomorrow!') | |
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
bcdedit /set {bootmgr} path \EFI\ubuntu\shimx64.efi |
OlderNewer