I hereby claim:
- I am bonprosoft on github.
- I am bonprosoft (https://keybase.io/bonprosoft) on keybase.
- I have a public key ASBbRLjzVR5Me9usSUt_2llTR4F3thx66jk3ujFK_v1jKAo
To claim this, I am signing this object:
import cProfile | |
import random | |
import cupy | |
from cupy import cudnn | |
libcudnn = cudnn.cudnn | |
N_LAYER = 10 | |
N_TESTCASE = 1000 |
#!/bin/bash | |
# CONFIGURATION | |
IN_DIR="fig_raw" | |
OUT_DIR="fig" | |
TARGET=("wmf" "emf") # NOTE: emf is only available under windows. | |
BASEDIR=`dirname $0` | |
BASEDIR=`(cd "${BASEDIR}"; pwd)` |
using System; | |
using System.Diagnostics; | |
using System.Runtime.CompilerServices; | |
namespace InlineConstant | |
{ | |
public class BaseClass | |
{ | |
protected virtual int GetConstValue() | |
{ |
I hereby claim:
To claim this, I am signing this object:
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var foo = new[] { 0, 1, 2, 3, 4 }.ToArray(); | |
var bar = new ArraySegment<int>(foo, 0, 2); | |
foo[0] = -1; | |
Console.WriteLine(ReferenceEquals(foo, bar.Array)); // True | |
Console.WriteLine(bar.ElementAt(0)); // -1 |
class Program | |
{ | |
static void Main(string[] args) | |
{ | |
var foo = SingletonClass<List<string>>.GetInstance(); | |
foo.Add("bbb"); | |
foo.Add("aaa"); | |
var anotherFoo = SingletonClass<List<string>>.GetInstance(); |
from azure.storage import BlobService | |
import os | |
import sys | |
BLOB_ACCOUNT = '[Input account name here]' | |
BLOB_ACCOUNTKEY = '[Input account key here]' | |
CONTAINER_NAME = '[Input container name here]' | |
TARGET_DIR = '[Input local data directory here]' |
Imports VBCPP | |
Imports VBCPPPlugin | |
Imports VBCPPPlugin.Exceptions | |
Imports VBCPPPlugin.Tables | |
Imports VBCPPPlugin.AST | |
Imports VBCPPPlugin.AST.AST_Class | |
Imports VBCPPPlugin.AST.AST_Enum | |
Module FizzBuzz | |
Sub Main() |
' ポイントはNewを殆ど使わず、メソッドチェーンで内容を付与していく点です。 | |
' この式では、なるべくカッコは使いたくなかったので、リストなどを作る際、子を作り終わったらDefineで親に戻ります。 | |
' LINQに触れてみて、感動したので、それに影響されたところがあります。 | |
'★長所: (他の式に比べて)なかなか書きやすい!★ | |
'★短所: Defineをしないうちは、別の中間生成物として表される必要が有るため、クラスが結構増える | |
Dim tree As New VBCPP_Program | |
tree.AddMethod( _ | |
VBCPP_Method.CreateNew("SampleMethod",System.Reflection.MethodAttributes.Static Or Reflection.MethodAttributes.Public,LangName,Line,FileName) _ | |
.SetBody _ |