QMCPACK / miniqmc

QMCPACK miniapp: a simplified real space QMC code for algorithm development, performance portability testing, and computer science experiments
Other
26 stars 35 forks source link

Rename mover to walker #221

Open ye-luo opened 5 years ago

ye-luo commented 5 years ago

I feel it is my fault that calling it mover which is a collection of ParticleSet, Wavefunction and random number generator (also hamiltonian). I think it should be correctly renamed to 'walker'. Any objection?

lshulen commented 5 years ago

I've got no problem with that. What would you think about creating something like a population class to hold walkers?

ye-luo commented 5 years ago

We use std::vector<Walker*> mover_list now. Do you have a particular reason to do something like

class population {
  std::vector<Walker*> mover_list;
}

Or

class population {
  std::vector<ParticleSet*>
  std::vector<WaveFunction*>
  ...
}

I think this is better.

Or you mean something else?

lshulen commented 5 years ago

I like the second one. It may also make sense to eventually move some of the generic methods to here rather than having to rely on generic_walker->waveFunction.method(blah....)

lshulen commented 5 years ago

In response to your question, I like having this sort of object because by passing it to a method to work on the population you can defer how it should be iterated over and it seems cleaner conceptually (to me).

PDoakORNL commented 5 years ago

Why not just refactor my crowd class to your liking? Does it need to be written from scratch again.

PDoakORNL commented 5 years ago

Population is a better name.

lshulen commented 5 years ago

Not opposed to that idea. It could be a good point of convergence.

ye-luo commented 5 years ago

I'm still digesting the Crowd class. I believe some portion will be moved to the develop. At the moment, I'm trying not to do drastic changes and settle a bit other changes first. I did see the miniqmc main routine gets very big and some effort will be needed to separate the main and drivers.

PDoakORNL commented 5 years ago

When I have some spare cycles I have a useful idea to generate the generic wrappers of the single evals in the class template declaration for Crowd as well as the default method definitions. These can be specialized when useful.