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
imp_logs.RecordUserAction(imp_logs.ROCK_PAPER_SCISSORS, "Save user actions", imp_logs.ActionRecordFormat{ | |
RoundID: pGame.GetRoundId(), | |
GameCode: pGame.GameCode, | |
Oid: pGame.GetOid(), | |
PfID: pPlayer.GetPfAccount(), | |
Data: PlayerActionESFormat{ | |
ActionType: request.Event, | |
Data: params.payload, | |
}, | |
}) |
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
export VSCODE_PATH=/Applications/Visual\ Studio\ Code.app/Contents/Resources/app | |
# Set name of the theme to load. Optionally, if you set this to "random" | |
# it'll load a random theme each time that oh-my-zsh is loaded. | |
# See https://github.com/robbyrussell/oh-my-zsh/wiki/Themes | |
ZSH_THEME="powerlevel9k/powerlevel9k" | |
# command line 左邊想顯示的內容 | |
POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(dir vcs) |
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
def combinations(n): | |
dp = [ [0 for _ in range(n)] for _ in range(n) ] | |
dp[0][0] = 1 | |
dp[1][1] = 1 | |
for i in range(2, n): | |
dp[i][1] = i | |
dp[i][i] = 1 | |
for j in range(2, n): |
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
def combinations(n): | |
dp = [ [0 for _ in range(n)] for _ in range(n) ] | |
dp[0][0] = 1 | |
dp[1][1] = 1 | |
for i in range(2, n): | |
dp[i][1] = i | |
dp[i][i] = 1 | |
for j in range(2, n): |
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
const path = require('path') | |
const fs = require('fs') | |
let cssFolder = path.resolve(__dirname, '../build/static/css') | |
let jsFolder = path.resolve(__dirname, '../build/static/js') | |
// var jsfiles = fs.readdirSync() | |
// read in css content | |
var cssContent = null |
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
.then(data => { | |
data.map(function(label) { | |
comment_count = 0; | |
label.processes.map(function(process) { | |
process.group.sentence = process.group.sentence.trim().split(','); | |
comment_count += process.group.sentence.length; | |
}); | |
label['comment_count'] = comment_count; | |
}); | |
}); |
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
from flask import render_template, request, redirect | |
from app.model import get_result_with_text | |
from app import app | |
conversations = [] | |
@app.route('/') | |
@app.route('/index') | |
def home(): |
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
# cuda path | |
export LD_LIBRARY_PATH="/usr/local/cuda-8.0/lib64:/usr/local/cuda-8.0/extras/CUPTI/lib64:$LD_LIBRARY_PATH" | |
export CUDA_HOME="/usr/local/cuda-8.0" | |
export PATH="$PATH:$CUDA_HOME/bin" | |
export CUDNN_HOME=${CUDA_HOME} | |
export TF_NEED_CUDA=1 | |
export CUDA_TOOLKIT_PATH=$CUDA_HOME | |
export TF_CUDA_VERSION=8.0 | |
export TF_CUDNN_VERSION=5 | |
export CUDNN_INSTALL_PATH=$CUDA_HOME |
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
echo 'Bob brought the pizza to Alice.' | syntaxnet/demo.sh | |
2017-04-19 16:47:21.770904: W external/org_tensorflow/tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.1 instructions, but these are available on your machine and could speed up CPU computations. | |
2017-04-19 16:47:21.770922: W external/org_tensorflow/tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use SSE4.2 instructions, but these are available on your machine and could speed up CPU computations. | |
2017-04-19 16:47:21.770928: W external/org_tensorflow/tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX instructions, but these are available on your machine and could speed up CPU computations. | |
2017-04-19 16:47:21.770930: W external/org_tensorflow/tensorflow/core/platform/cpu_feature_guard.cc:45] The TensorFlow library wasn't compiled to use AVX2 instructions, but these are available on your machine and could spee |
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
#include <stdio.h> | |
#include <stdlib.h> | |
#include <string.h> | |
#include <sys/types.h> | |
#include <sys/socket.h> | |
#include <netinet/in.h> | |
#include <arpa/inet.h> | |
#define BUFFER_SIZE 512 | |
#define SERVER_PORT 3000 |
NewerOlder