This file contains 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
HDC hdc = GetDC(NULL); // get the desktop device context | |
HDC hDest = CreateCompatibleDC(hdc); // create a device context to use yourself | |
// get the height and width of the screen | |
int height = GetSystemMetrics(SM_CYVIRTUALSCREEN); | |
int width = GetSystemMetrics(SM_CXVIRTUALSCREEN); | |
// create a bitmap | |
HBITMAP hbDesktop = CreateCompatibleBitmap( hdc, width, height); |
This file contains 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
#!/bin/bash | |
action=$1; uri=$2; shift; shift; | |
case "$action" in | |
GET) | |
curl -XGET "localhost:9200/$uri?pretty=1" "$@" | |
;; | |
PUT) | |
curl -XPUT "localhost:9200/$uri?pretty=1" "$@" | |
;; |
This file contains 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
server { | |
listen 80; | |
server_name example.org; | |
return 301 http://www.example.org$request_uri; | |
} | |
This file contains 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
server { | |
server_name example.com ; | |
access_log /var/log/nginx/example.com.access.log; | |
error_log /var/log/nginx/example.com.error.log debug; | |
root /var/www/example.com/htdocs ; | |
index index.php; | |
if (!-e $request_filename) { |
This file contains 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
<!DOCTYPE html> | |
<!--[if lt IE 9]> | |
<html class="lt-ie9" lang="zh-CN"> | |
<![endif]--> | |
<!--[if gte IE 9]> --> | |
<html lang="zh-CN"> | |
<!--<![endif]--> | |
<head> | |
<meta charset="utf-8" /> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0" /> |
This file contains 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
#!/bin/sh | |
killall -HUP mDNSResponder | |
killall mDNSResponderHelper | |
dscacheutil -flushcache |
This file contains 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
#!/bin/bash |
This file contains 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
{"sig":"cccea3c025698294837b8e2442b2868b8f1fe1b033a202e93aac77f8a36befcbcda8c9113229c5d82649527f7052aa02a60abe86afab8e46f0d2f5b293651b7b0","msghash":"22dfc290a00344129a64c53aa83b63095283d55f7390ccdcd06f11db0e7154bc"} |
This file contains 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
#!/bin/sh | |
# This script is used to config tensorflow docker runtime environment on aliyun. | |
# System should be Ubuntu 16.04 | |
# echo Install NVIDIA driver | |
# sudo add-apt-repository ppa:graphics-drivers | |
# sudo apt-get update | |
# sudo ubuntu-drivers devices | |
# https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-using-the-repository |
This file contains 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
# coding: utf-8 | |
# Low Memory VGG model. | |
import os | |
import numpy as np | |
import pandas as pd | |
import tensorflow as tf | |
from tensorflow.python.client import timeline | |
tf.logging.set_verbosity(tf.logging.DEBUG) |
OlderNewer