Commit 8c70fa61 authored by Adam Štěpánek's avatar Adam Štěpánek
Browse files

Merge branch 'master' of gitlab.fi.muni.cz:xstepan1/secret-hitler

parents 1e3d1df9 356a7274
Loading
Loading
Loading
Loading
+14 −20
Original line number Diff line number Diff line
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
@@ -9,11 +8,6 @@ using Adam.SecretHitler.Cfr;

namespace Adam.SecretHitler.Analysis
{
    public enum AnalType
    {
        Grid
    };

    public struct Result
    {
        string LiberalStrategy;
@@ -88,27 +82,27 @@ namespace Adam.SecretHitler.Analysis
        {
            this.random = new Random(randomState);
            this.liberalPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_liberal", () => new SimpleStrategy.Liberal()},
                {"random_liberal", () => new RandomStrategy(random)},
                {"cfr_6Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-6000000")},
                {"cfr_107Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-107000000")},
                {"cfr_218Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-218000000")},
                {"simple_liberal", () => new SimpleStrategy.Liberal()},
                {"paranoid_liberal", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
            this.fascistPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_fascist", () => new SimpleStrategy.Fascist(random)},
                {"random_fascist", () => new RandomStrategy(random)},
                {"counter_fascist", () => new CounterSimpleStrategy(random)},
                {"cfr_6Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-6000000")},
                {"cfr_107Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-107000000")},
                {"cfr_218Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-218000000")},
                {"simple_fascist", () => new SimpleStrategy.Fascist(random)},
                {"countersimple_fascist", () => new CounterSimpleStrategy(random)},
                {"paranoid_fascist", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
            this.hitlerPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_hitler", () => new SimpleStrategy.Hitler()},
                {"random_hitler", () => new RandomStrategy(random)},
                {"counter_hitler", () => new CounterSimpleStrategy(random)},
                {"cfr_6Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-6000000")},
                {"cfr_107Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-107000000")},
                {"cfr_218Ms", () => new CfrTrainedStrategy(random, "Release/netcoreapp3.1/outputs/cfr-random-132347266894798737/cfr-218000000")},
                {"simple_hitler", () => new SimpleStrategy.Hitler()},
                {"countersimple_hitler", () => new CounterSimpleStrategy(random)},
                {"paranoid_hitler", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
        }

+20 −18
Original line number Diff line number Diff line
using System;
using System.Collections.Concurrent;
using System.Collections.Generic;
using System.Collections.Immutable;
using System.IO;
using System.Linq;
using System.Threading.Tasks;
using Adam.SecretHitler.Cfr;
using System.Diagnostics;

namespace Adam.SecretHitler.Analysis
{
@@ -53,21 +49,27 @@ namespace Adam.SecretHitler.Analysis
        {
            this.random = new Random(randomState);
            this.liberalPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_liberal", () => new SimpleStrategy.Liberal()},
                {"random_liberal", () => new RandomStrategy(random)},
                {"simple_liberal", () => new SimpleStrategy.Liberal()},
                {"paranoid_liberal", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
            this.fascistPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_fascist", () => new SimpleStrategy.Fascist(random)},
                {"random_fascist", () => new RandomStrategy(random)},
                {"counter_fascist", () => new CounterSimpleStrategy(random)},
                {"simple_fascist", () => new SimpleStrategy.Fascist(random)},
                {"countersimple_fascist", () => new CounterSimpleStrategy(random)},
                {"paranoid_fascist", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
            this.hitlerPool = new Dictionary<string, Func<IStrategy>>{
                {"naive_hitler", () => new SimpleStrategy.Hitler()},
                {"random_hitler", () => new RandomStrategy(random)},
                {"counter_hitler", () => new CounterSimpleStrategy(random)},
                {"simple_hitler", () => new SimpleStrategy.Hitler()},
                {"countersimple_hitler", () => new CounterSimpleStrategy(random)},
                {"paranoid_hitler", () => new ParanoidStrategy(random)},
                {"cfr_1Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-1000000")},
                {"cfr_9Ms", () => new CfrTrainedStrategy(random, "trained_cfr/cfr-9000000")},
            };
            this.liberalCounts = new Dictionary<string, double>();
            this.fascistCounts = new Dictionary<string, double>();
+567 −243

File changed.

Preview size limit exceeded, changes collapsed.

+46 −52

File changed.

Preview size limit exceeded, changes collapsed.

+1800 −1800

File changed.

Preview size limit exceeded, changes collapsed.