-
Notifications
You must be signed in to change notification settings - Fork 18.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Solver Refactor: Separate files and Change Solver's Type to String #3116
Conversation
To provide correct level of solver abstractions, I hope the hierarchy would be
Any suggestions are welcome! |
@shelhamer Do you prefer that I address all the above tasks in one PR, or should I split them into separate PRs (I am in favor of the latter)? |
@ronghanghu you are welcome to do it as a progression but certain tasks need to be done together such as
so that each PR yields a correct master. Thank you for bringing order to the solver code! |
d1e18af
to
798ce46
Compare
I feel it is better to split this PR into two separate PRs, one for splitting files and one for solver abstraction. Part 1 should be (almost) completed. |
88f0830
to
3334fdb
Compare
5244a8d
to
37755b4
Compare
9692f71
to
ec972e8
Compare
ec972e8
to
80cc600
Compare
A rebase is needed here after #3204. |
@ronghanghu sorry about that! I'm happy to do a last review and merge after the rebase so we can have orderly solver code. |
80cc600
to
834a98b
Compare
834a98b
to
9563537
Compare
Rebased to the latest master |
Solver Refactor: Separate files and Change Solver's Type to String
Thanks for splitting up the solvers and decoupling development Ronghang! |
Resolve #2890.
Split
solver.cpp
into each solver per file, allow self-contained solver development, and provide abstraction for adaptive gradient solvers.Caffe has individual cpp files for each layer, and in #1694, layer types were changed to strings to allow self-contained layer development. Similar work should be done for solvers, especially given that right now all solver implementations are in
solver.cpp
and their tests intest_gradient_based_solver.cpp
, both 1200+ lines.Part 1: Solver Refactor
Note: The old enum field
solver_type
is changed to the new string fieldtype
inSolverParameter
. Automatic upgrade provided.Part 2: Solver Abstraction (in another PR)