Giter Site home page Giter Site logo

experimental's People

Contributors

u-ma avatar

Watchers

 avatar  avatar

experimental's Issues

root.count_がmcts_count+1になっている

最初の顧客を選択するときのモンテカルロ木を出力するようにすると
root.count_の値がmcts_count+1になっている。


diff --git a/src/main.cpp b/src/main.cpp
index 4d25797..a325595 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -154,6 +154,7 @@ main(int argc, char **argv)

             return 1;
         }
         transition(solution, host_vrp, next->customer_id());
+        VrpSolver::tools::node_dump(stderr, root, 1); exit(1);^M
     }
     clock_t stop = clock();

./a.out ../cvrp/experiment/Vrp-All/E/E-n51-k5.vrp 800 800 10 120
node_id:ROOT
count:801,num_childs: 50
child:
node_id:1
count: 16,num_childs: 49
node_id:2
count: 14,num_childs: 49
node_id:3
count: 16,num_childs: 49
...

node_dumpの出力先

node_dumpの出力先が現在stdoutなので、指定のファイルに出力することを可能にするように変更すべき。

node_dump(fp, root, 1);

SolutionHelperをmain.cppに移動

SolutionHelperは実質、車両の変更か顧客へ進むかの条件分岐を関数としてラップしたものである。
そして、SolutionHelperはmain関数でしか使用されないのでmain.cppに移動させてもよいのではないだろうか。

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.