aiidateam / aiida-wannier90

AiiDA plugin for the Wannier90 code
https://aiida-wannier90.readthedocs.io
Other
9 stars 15 forks source link

Mutually exclusive remote_input_folder and local_input_folder #76

Closed greschd closed 4 years ago

greschd commented 4 years ago

Related to #69, #37, #14.

Currently, the logic for selecting input files needs to get the list of files in the RemoteData. This opens an SSH transport -- if that fails, the calculation will except, because there is no retry mechanism. In addition, if there are many calculation the remote might block connections. Unlike the regular transport, SSH connections are not re-used. As far as I can tell, there is no easy resolution for this.

A way to avoid having to know the content in the remote_input_folder in the first place would be allowing only either local_input_folder or remote_input_folder, not both at the same time. I discussed this with @giovannipizzi and @AntimoMarrazzo, but we are not 100% sure that all current use cases are covered by this.

@normarivano @qiaojunfeng is this compatible with your current workflows / use cases?

normarivano commented 4 years ago

Me and @qiaojunfeng we checked and discussed together. In our opinion it should be fine but we are not completely sure. No obvious cases came to our mind by the way.

greschd commented 4 years ago

Ok, I will go ahead with this, then. If the need arises we can always implement this (should be possible in a backwards-compatible way).

giovannipizzi commented 4 years ago

Thanks @greschd - yes, please go ahead! I'll also added this to the 2.0 milestone as it's backward-incompatible

giovannipizzi commented 4 years ago

Just as a note for @greschd - you might want to check if this comment still holds or needs a fix: https://github.com/aiidateam/aiida-wannier90/blob/2b6084608a452614413f32a64669680210298660/aiida_wannier90/calculations.py#L306

Also, probably the fix will always solve #37

greschd commented 4 years ago

See my comment on #37 -- let's continue the discussion there.

greschd commented 4 years ago

Small question: In pp_setup mode, should we allow setting any input folders? Currently it's allowed, but AFAIK it doesn't really make sense.

giovannipizzi commented 4 years ago

Agreed - no input folders in pp_setup mode (maybe then we can just use the presence of an input to decide if we are running in pp_setup mode?)

greschd commented 4 years ago

Not sure about that.. maybe it's a bit too easy to accidentally run in pp_setup mode then?