spot_request.py
- request spot instance
- wait for running
- print IP address
aws_run.py
- rsync
- nohup run command
# --------------------------------------------------------------------- | |
# PowershellからC#コードをコンパイル・実行するサンプル | |
# | |
# (参考) | |
# http://codezine.jp/article/detail/5007 | |
# | |
# (注意点) | |
# .NET Frameworkの制約上、Add-Typeによる型の追加を再実行するには、Powershellのセッションを切る必要がある。 | |
# そのため、Powershellのプロセスを立ち上げ、その中でコンパイル・実行するようにしている。 | |
# --------------------------------------------------------------------- |
FROM nvidia/cuda:10.0-cudnn7-devel-ubuntu18.04 | |
# reference: https://hub.docker.com/r/nejumi/tools_for_kaggle/dockerfile | |
ARG DEBIAN_FRONTEND=noninteractive | |
RUN apt-get update && \ | |
apt-get install -y software-properties-common && \ | |
add-apt-repository ppa:git-core/ppa && \ | |
apt-get update && \ | |
apt-get install -y git build-essential cmake && \ | |
git --version |
import numpy as np | |
import pandas as pd | |
if __name__ == "__main__": | |
import glob | |
files = glob.glob("src/*") | |
print(files) | |
ls_using = [] | |
ls_main = [] |
#!/bin/bash | |
# utils | |
cd ~/ | |
mkdir proj lib | |
sudo apt-get update | |
sudo apt-get install -y git build-essential libatlas-base-dev | |
sudo apt-get install -y python3-dev | |
git config --global credential.helper 'cache --timeout=3600' | |
git config --global user.email "xxxx@xxxx.com" |
from util_log import Logger | |
logger = Logger() | |
from collections import OrderedDict | |
logger.info("run started") | |
d = OrderedDict([('run_name', "xgb_1"), ('fold', 0), ('logloss', 0.66)]) | |
logger.result_ltsv_time(d) |
# coding:utf-8 | |
# args | |
import argparse | |
parser = argparse.ArgumentParser() | |
parser.add_argument("--test", action="store_true") | |
parser.add_argument("--prms", type=int, action="store", default=0) | |
args = parser.parse_args() | |
TEST = args.test |
#!/usr/bin/env python | |
# ---------------------------------------------------------------------------- | |
# Copyright 2015 Nervana Systems Inc. | |
# Licensed under the Apache License, Version 2.0 (the "License"); | |
# you may not use this file except in compliance with the License. | |
# You may obtain a copy of the License at | |
# | |
# http://www.apache.org/licenses/LICENSE-2.0 | |
# | |
# Unless required by applicable law or agreed to in writing, software |
spot_request.py
aws_run.py
# 質問 ----------------------------------------------------------------------------------- | |
# | |
# ・ Generalized Linear Models for Insurance Dataが無料公開されているとお聞きしたのですが、 | |
# 有料のものしか見つけられませんでした。 | |
# ⇒無くなったらしい。残念。 | |
# | |
# ・ 関数Cでcontrast matrixというものを指定し、因子の基準を指定できるようなのですが、 | |
# どうも上手くいかないようで、テキストと異なる係数になりました。 | |
# (Model_EとModel_E2 参照) | |
# ⇒チーム内メンバーで、Model_EとModel_E2が同じ係数となる人、違う係数となる人がいるようで、 |
# 適切なカレントディレクトリを設定した上で、このスクリプトを実行下さい。 | |
# .NET Frameworkのカレントディレクトリをセット | |
[IO.Directory]::SetCurrentDirectory((Get-Location).ProviderPath) | |
# ユーティリティ関数の読み込み | |
. .\textmanip.ps1 | |
# テスト用フォルダの作成 | |
TestFileCreate "test sample1\1.txt" 1000 |