gcc -O2 -mavx512f vector.c -fopt-info-vec-all -S -o vector.s
gcc -O2 -mavx512f vector.c -fopt-info-vec-all -c -o vector
gcc -O0 -mavx512f test3.c -fopt-info-vec-all -o test3 vector
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
# -*- coding: utf-8 -*- | |
import statsmodels.api as sm | |
import pandas as pd | |
from matplotlib import pyplot as plt | |
def main(): | |
# 過去の案件データの取り込み(診断工数、画面数、診断員の経験値、Webサーバのレスポンス速度) | |
data = pd.read_csv('cpu_scores.csv', skiprows=1, names=['cores', 'threads', 'base_clock', 'boost_clock', 'L1_cache', 'L2_cache', 'L3_cache', 'CinebenchR20'], encoding='UTF_8') | |
# 画面数、診断員の経験値、Webサーバのレスポンス速度を説明変数として定義 |
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
set tabstop=4 | |
set shiftwidth=4 | |
set expandtab |
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
# docker build -f Dockerfile . -t wasm-builder | |
# docker run -it -v `pwd`:/root/wasm wasm-builder bash | |
FROM ubuntu:latest | |
RUN apt update | |
RUN apt install -y llvm git python vim libxml2 | |
WORKDIR /root | |
RUN git clone https://github.com/emscripten-core/emsdk.git |
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 jdk.incubator.vector.*; | |
/* | |
javac14 src/main/java/VectorTest.java \ | |
--add-modules jdk.incubator.vector \ | |
-d out/ | |
java14 -cp out/ VectorTest | |
@see http://cr.openjdk.java.net/~kkharbas/vector-api/CSR/javadoc.02/jdk.incubator.vector/jdk/incubator/vector/package-summary.html |
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 numpy as np | |
from PIL import Image | |
from ISR.models import RDN | |
from tensorflow.compat.v1 import ConfigProto | |
from tensorflow.compat.v1 import InteractiveSession | |
config = ConfigProto() | |
config.gpu_options.allow_growth = True | |
session = InteractiveSession(config=config) |
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
package com.horitaku1124.java.event; | |
import java.io.IOException; | |
import java.nio.file.*; | |
import java.util.function.Consumer; | |
public class Eventer { | |
public static void getEvent(String filPath, Consumer<Path> callback) { | |
try { | |
Path filePath = Paths.get(filPath); |
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 java.math.BigDecimal; | |
import java.math.RoundingMode; | |
class CalcPi { | |
public static void main(String[] args) { | |
var start = System.currentTimeMillis(); | |
final long RADIUS = 3000000000L; | |
final long RADIUS_E2 = RADIUS * RADIUS; | |
long count = 0; | |
System.out.println("RADIUS_E2=" + RADIUS_E2); |
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
function formatString(...args) { | |
let format = args[0]; | |
let result = format; | |
let matches = format.match(/(%(s|\d*d))/g); | |
for (let i = 0;i < matches.length;i++) { | |
let replaceFrom = matches[i]; | |
let replaceTo = args[i + 1].toString(); | |
if (replaceFrom === "%s" || replaceFrom === "%d") { | |
result = result.replace(matches[i], replaceTo); | |
} else { |
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 numpy as np | |
from PIL import Image | |
from ISR.models import RDN | |
img_name = './data/meerkat.png' | |
img = Image.open(img_name) | |
print(img.size) | |
scale = 2 |