You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
For some, especially smaller, files one could enhance the user experience by automatic retrieval and automatic parsing. I especially think of the the MSD and radial distribution functions.
For the RDF i currently use something like
# ToDo: this is not really elegant, optimize it
if 'ComputeRDF' in self.ctx.parameters['GeneralSettings'].keys():
if self.ctx.parameters['GeneralSettings']['ComputeRDF'] in [
'yes', 'YES', 'Yes'
]:
self.ctx.settings = ParameterData(
dict={
'additional_retrieve_list':
['RadialDistributionFunctions/System_0/*'],
})
which of course would be needed to be generalized to multiple systems. It can get large if the user specifies a lot of different atom types.
In my case, I also parse the RDF. One could save space by saving r only once as it is the same for all files.
def parse_rdfs(rdf_file_list):
rdf_dict = {}
for file in rdf_file_list:
name = Path(file).stem.strip('RDF_')
df = pd.read_csv(file, comment='#', header=None, sep='\s+')
r = df.iloc[:, 0].values
rdf = df.iloc[:, 1].values
rdf_dict[name] = {'r': r, 'rdf': rdf}
return rdf_dict
Needs discussion.
For some, especially smaller, files one could enhance the user experience by automatic retrieval and automatic parsing. I especially think of the the MSD and radial distribution functions.
For the RDF i currently use something like
which of course would be needed to be generalized to multiple systems. It can get large if the user specifies a lot of different atom types.
In my case, I also parse the RDF. One could save space by saving r only once as it is the same for all files.
Linking @danieleongari for notice.
The text was updated successfully, but these errors were encountered: