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
// メモデータに関するモデル処理 | |
// 1件分のメモデータ | |
class Item { | |
final int id; // ユニークな識別子 | |
final String title; // メモのタイトル | |
final String memo; // メモの内容 | |
// コンストラクタ | |
const Item({ |
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
// メモデータに関するモデル処理 | |
// 1件分のメモデータ | |
class Item { | |
final int id; // ユニークな識別子 | |
final String title; // メモのタイトル | |
final String memo; // メモの内容 | |
// コンストラクタ | |
const Item({ |
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
// メモデータに関するモデル処理 | |
// 1件分のメモデータ | |
class Item { | |
final int id; // ユニークな識別子 | |
final String title; // メモのタイトル | |
final String memo; // メモの内容 | |
// コンストラクタ | |
const Item({ |
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
// メモデータに関するモデル処理 | |
import 'package:flutter/foundation.dart'; | |
import 'package:path/path.dart'; | |
import 'package:sqflite/sqflite.dart'; | |
// 1件分のメモデータ | |
class Item { | |
final int id; | |
final String title; |
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
import 'package:meta/meta.dart'; | |
// 1件分のメモデータ | |
class Item { | |
final int id; | |
final String title; | |
final String memo; | |
// idを時刻データにする | |
const Item({this.id = -1, required this.title, required this.memo}); |
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
import time | |
from selenium import webdriver | |
from selenium.webdriver.common.by import By | |
browser = webdriver.Chrome() | |
browser.get('https://www.google.co.jp') | |
fakebox = browser.find_element(By.XPATH, | |
'/html/body/div[1]/div[3]/form/div[1]/div[1]/div[1]/div/div[2]/input') |
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
!apt -qq -y install xvfb freeglut3-dev ffmpeg | |
!pip -q install pyopengl | |
!pip -q install pyvirtualdisplay | |
# 結果出力描画のための準備 | |
from pyvirtualdisplay import Display | |
import cv2 | |
from IPython.display import HTML | |
import numpy as np | |
from base64 import b64encode |
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
# 関連パッケージのインストール | |
!apt -qq update | |
!apt -qq -y install libnvtoolsext1 | |
!apt -qq -y install xvfb freeglut3-dev ffmpeg | |
!pip -q install gym | |
!pip -q install pyglet | |
!pip -q install pyopengl | |
!pip -q install pyvirtualdisplay | |
# 結果出力描画のための準備 |
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
import numpy as np | |
import matplotlib.pyplot as plt | |
import seaborn as sns | |
class DPAgent: | |
def __init__(self, env, gamma=0.9): | |
self.env = env | |
self.gamma = gamma | |
self.reset() |
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
import numpy as np | |
import matplotlib.pyplot as plt | |
import seaborn as sns | |
class DPAgent: | |
def __init__(self, env, gamma=0.9): | |
self.env = env | |
self.gamma = gamma | |
self.reset() |