SlideShare une entreprise Scribd logo
1  sur  34
Télécharger pour lire hors ligne
de:code 2019
C# ドキドキ・ライブコーディング対決 @ de:code
- ONLY C#!! Blazor Web 開発バトル -
小島の分
MW51
小島 富治雄
福井コンピュータ グループ
Microsoft MVP for Developer Technologies
自己紹介
過去の対戦での工夫
今回の
7並べの
戦略
9
自分の役割は何か?
~役割に合った戦略を~
役割を考える
今回の戦略は2つ
ざわ…
ざわ…
イ
カ
サ
マ
だ
!
戦略 その1 「対 チート」
public interface IPlayer
{
...
// 自分の手番で出すカードを返す
Card PutCard(IList<Card> myCards,
IList<Card> cardsOnTable, // テーブルのカード
IDictionary<IPlayer, int> playerPassCount); // 全員のパスの回数
}
今回の各自が実装するコード
誰かが工夫を
仕掛けてこない
理由がない
過去に「オセロ対決の最初の手番で盤面を全部自分の石にした」人がいる
// チートがあったら自分の手札とパスの回数を戻して、
if (RestoreAgainstCheat(myCards, playerPassCount))
// 不正を報告する
// (IFTTT を使って、Twitter に #decode19 付きで晒上げるか?)
ReportCheat();
「対 チート」 対策
戦略 その2 「ML (Machine Learning: 機械学習)」
先ずは学習用データの準備
局面を数値化
0
1
2
1
0 0 0 1 0 2 2 2 2 0 0 0 0
0 1 0 0 0 1 2 0 0 0 1 0 0
0 1 1 0 2 2 2 2 1 0 0 0 0
0 0 1 0 0 1 2 2 2 1 0 0 0
局面を数値化
GameRunner ツールの作成
GameRunner ツールの作成
一回目のデータ
機械学習の流れ (Machine Learning)!
GameRunner
Azure SQL
Database
クラウドに保存
Azure Machine
Learning
Studio
機械学習で解析!
沢山戦わせた局面
と勝敗のデータ
のべの計算時間
10時間
ML で作成した学習
モデルで AI を作成
繰り返して
モデルを洗練
Azure SQL Database
Azure SQL Database
Azure Machine Learning Studio
Azure Machine Learning Studio
Azure Machine Learning Studio
Azure Machine Learning Studio
機械学習の流れ (Machine Learning)!
GameRunner
Azure SQL
Database
クラウドに保存
Azure Machine
Learning
Studio
機械学習で解析!
沢山戦わせた局面
と勝敗のデータ
のべの計算時間
10時間
ML で作成した学習
モデルで AI を作成
何度も繰り返す
ことでより強く!
Machine Learning
あれ?
なんか違和感。
忘れてることない?
クロス ドメイン
クロス ドメイン対策
クロス ドメイン対策
ざわ…
ざわ…
Currently, we don‘t
support disabling
CORS on API side.
マジか。
クロス ドメイン対策
ざわ…
ざわ…
Web 上の API が呼べ
ないなら、ML.NET を
使えばよいじゃない
マジか。いや、それが
… …
ML.NET は?
public class PlayerKojima : IPlayer
{
public override string PalyerName { get => "小島"; }
public override string PalyerImageName { get => "kojima.jpg"; }
public Card PutCard(IList<Card> myCards, IList<Card> cardsOnTable,
IDictionary<IPlayer, int> playerPassCount)
{ … }
}
結局、手でロジックを組んで API で評価
ボロ…
ボロ…
ボロ…
Deep
Shallow
Learning!
圧倒的、浅さっ…!
最後に… Blazor の感想
ねぇ、L は?
L はどこからきたの?

Contenu connexe

Plus de Fujio Kojima

Plus de Fujio Kojima (20)

C#の新機能勉強会 ~ C#7、8の新機能を活用して速く安全なプログラムを書こう~
C#の新機能勉強会 ~ C#7、8の新機能を活用して速く安全なプログラムを書こう~C#の新機能勉強会 ~ C#7、8の新機能を活用して速く安全なプログラムを書こう~
C#の新機能勉強会 ~ C#7、8の新機能を活用して速く安全なプログラムを書こう~
 
C# ドキドキ ライブ コーディング!! ~ 小島の分 ~ | BuriKaigi 2020
C# ドキドキ ライブ コーディング!! ~ 小島の分 ~ | BuriKaigi 2020C# ドキドキ ライブ コーディング!! ~ 小島の分 ~ | BuriKaigi 2020
C# ドキドキ ライブ コーディング!! ~ 小島の分 ~ | BuriKaigi 2020
 
牛タン会議 2019 @ 仙台 「C# ドキドキ ライブ!!」 小島の分
牛タン会議 2019 @ 仙台 「C# ドキドキ ライブ!!」 小島の分牛タン会議 2019 @ 仙台 「C# ドキドキ ライブ!!」 小島の分
牛タン会議 2019 @ 仙台 「C# ドキドキ ライブ!!」 小島の分
 
『機械学習 (AI/ML) の基礎と Microsoft の AI | 2019/04/02 Global AI Nights Fukui
『機械学習 (AI/ML) の基礎と Microsoft の AI | 2019/04/02 Global AI Nights Fukui『機械学習 (AI/ML) の基礎と Microsoft の AI | 2019/04/02 Global AI Nights Fukui
『機械学習 (AI/ML) の基礎と Microsoft の AI | 2019/04/02 Global AI Nights Fukui
 
機械学習 (AI/ML) 勉強会 #2 IoT編
機械学習 (AI/ML) 勉強会 #2 IoT編 機械学習 (AI/ML) 勉強会 #2 IoT編
機械学習 (AI/ML) 勉強会 #2 IoT編
 
機械学習 (AI/ML) 勉強会 #1 基本編
機械学習 (AI/ML) 勉強会 #1 基本編機械学習 (AI/ML) 勉強会 #1 基本編
機械学習 (AI/ML) 勉強会 #1 基本編
 
BuriKaigi2019 「C# ドキドキ・ライブコーディング」 小島の分
BuriKaigi2019 「C# ドキドキ・ライブコーディング」 小島の分BuriKaigi2019 「C# ドキドキ・ライブコーディング」 小島の分
BuriKaigi2019 「C# ドキドキ・ライブコーディング」 小島の分
 
機械学習入門
機械学習入門機械学習入門
機械学習入門
 
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しようC# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
C# でニューラルネットワークをスクラッチで書いて機械学習の原理を理解しよう
 
C# LINQ ~深く知って、使いまくろう~
C# LINQ ~深く知って、使いまくろう~C# LINQ ~深く知って、使いまくろう~
C# LINQ ~深く知って、使いまくろう~
 
「ふくいソフトウェアコンペティション 2014 大賞受賞者プレゼンテーション」
「ふくいソフトウェアコンペティション 2014 大賞受賞者プレゼンテーション」「ふくいソフトウェアコンペティション 2014 大賞受賞者プレゼンテーション」
「ふくいソフトウェアコンペティション 2014 大賞受賞者プレゼンテーション」
 
.NET MVP によるドキドキ・ライブコーディング! 小島の分
.NET MVP によるドキドキ・ライブコーディング! 小島の分.NET MVP によるドキドキ・ライブコーディング! 小島の分
.NET MVP によるドキドキ・ライブコーディング! 小島の分
 
Windows アプリケーション開発 はじめに ~ Windows アプリケーション開発初学者の方向け Visual Studio を使ったアプリケーショ...
Windows アプリケーション開発はじめに ~ Windows アプリケーション開発初学者の方向けVisual Studio を使ったアプリケーショ...Windows アプリケーション開発はじめに ~ Windows アプリケーション開発初学者の方向けVisual Studio を使ったアプリケーショ...
Windows アプリケーション開発 はじめに ~ Windows アプリケーション開発初学者の方向け Visual Studio を使ったアプリケーショ...
 
HTML5 on ASP.NET
HTML5 on ASP.NETHTML5 on ASP.NET
HTML5 on ASP.NET
 
最新C#動向と関数型言語haskell ~命令型静的プログラミングから関数型動的プログラミングへのシフト~
最新C#動向と関数型言語haskell ~命令型静的プログラミングから関数型動的プログラミングへのシフト~最新C#動向と関数型言語haskell ~命令型静的プログラミングから関数型動的プログラミングへのシフト~
最新C#動向と関数型言語haskell ~命令型静的プログラミングから関数型動的プログラミングへのシフト~
 
C# 式木 (Expression Tree) ~ LINQをより深く理解するために ~
C# 式木 (Expression Tree) ~ LINQをより深く理解するために ~C# 式木 (Expression Tree) ~ LINQをより深く理解するために ~
C# 式木 (Expression Tree) ~ LINQをより深く理解するために ~
 
C# 6.0 Preview
C# 6.0 PreviewC# 6.0 Preview
C# 6.0 Preview
 
Microsoft .NET 入門
Microsoft .NET 入門Microsoft .NET 入門
Microsoft .NET 入門
 
Visual Studio による開発環境・プログラミングの進化
Visual Studio による開発環境・プログラミングの進化Visual Studio による開発環境・プログラミングの進化
Visual Studio による開発環境・プログラミングの進化
 
F流 『オブジェクト指向の考え方の基礎の基礎』 ~ソフトウェア開発の原則編~
F流『オブジェクト指向の考え方の基礎の基礎』~ソフトウェア開発の原則編~F流『オブジェクト指向の考え方の基礎の基礎』~ソフトウェア開発の原則編~
F流 『オブジェクト指向の考え方の基礎の基礎』 ~ソフトウェア開発の原則編~
 

Dernier

IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
Enterprise Knowledge
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Dernier (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Tech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdfTech Trends Report 2024 Future Today Institute.pdf
Tech Trends Report 2024 Future Today Institute.pdf
 
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
08448380779 Call Girls In Diplomatic Enclave Women Seeking Men
 
IAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI SolutionsIAC 2024 - IA Fast Track to Search Focused AI Solutions
IAC 2024 - IA Fast Track to Search Focused AI Solutions
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
Raspberry Pi 5: Challenges and Solutions in Bringing up an OpenGL/Vulkan Driv...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men08448380779 Call Girls In Friends Colony Women Seeking Men
08448380779 Call Girls In Friends Colony Women Seeking Men
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
04-2024-HHUG-Sales-and-Marketing-Alignment.pptx
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Presentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreterPresentation on how to chat with PDF using ChatGPT code interpreter
Presentation on how to chat with PDF using ChatGPT code interpreter
 
Evaluating the top large language models.pdf
Evaluating the top large language models.pdfEvaluating the top large language models.pdf
Evaluating the top large language models.pdf
 
08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men08448380779 Call Girls In Civil Lines Women Seeking Men
08448380779 Call Girls In Civil Lines Women Seeking Men
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 

de:code 2019 MW51 「C# ドキドキ・ライブコーディング対決」 小島の分