Using My Own Data-ASE-Readable Files-POSCAR

I just want predict my own data with POSCAR by using equiformer_v2, and I changed the config files.
The error in the code is a little confusing to me, and I don’t know how to modify it.
The error is as follows:
OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade per
formance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by a
voiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment va
riable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.

And my config files:
task:
dataset: ase_read

dataset:
train:
src: ‘D:\data\ldh’ # The folder that contains ASE-readable files
pattern: '/POSCAR’ # Pattern matching each file you want to read (e.g. "/POSCAR"). Search recursively with two wildcards: “**/*.cif”.

  ase_read_args:
    # Keyword arguments for ase.io.read()
    format: vasp
    index: '0'
  a2g_args:
    # Include energy and forces for training purposes
    # If True, the energy/forces must be readable from the file (ex. OUTCAR)
    r_energy: True
    r_forces: True
  keep_in_memory: False

#logger: tensorboard
ocp-main\configs\s2ef\2M\equiformer_v2\equiformer_v2_N@12_L@6_M@2.yml is not change.

Hello,

Thanks for getting in touch about this issue! Let’s see if we can isolate the problem to the dataset loading itself or determine if there is another issue with the ocpmodels code in general.

Could you please try running this test:

from ocpmodels.datasets.ase_datasets import AseReadDataset

ds = AseReadDataset(config = {
    'src': 'D:\data\ldh',
    'pattern': '**\POSCAR',
})

print(f'Dataset length: {len(ds)}')
print(ds[0])
1 Like

Sure, it also have the same error.

The error is as follows:

  • Dataset length: 652
  • OMP: Error #15: Initializing libiomp5md.dll, but found libiomp5md.dll already initialized.
  • OMP: Hint This means that multiple copies of the OpenMP runtime have been linked into the program. That is dangerous, since it can degrade performance or cause incorrect results. The best thing to do is to ensure that only a single OpenMP runtime is linked into the process, e.g. by avoiding static linking of the OpenMP runtime in any library. As an unsafe, unsupported, undocumented workaround you can set the environment variable KMP_DUPLICATE_LIB_OK=TRUE to allow the program to continue to execute, but that may cause crashes or silently produce incorrect results. For more information, please see http://www.intel.com/software/products/support/.

I suspect that this is an issue related to the installation environment and not a problem with your dataset or ocpmodels itself. Could you confirm that ocpmodels is installed according to these instructions?

Also, this thread suggests reinstalling numpy.

Thanks!I uninstall my numpy, and install numpy.

Sorry, I have another problem, I want to use my own data POSCAR to OC22-S2EF training, but it keeps giving me errors. Because there is an example of jupyter notebook and an example of Using an ASE Database in TRAIN.md in the source code I found on github, but it is difficult for me to use these two parts together. I wonder if you can provide me with an example. Use your own POSCAR to train yml files (in any model).

Here is an example you may be interested in. It is possible to use Python dictionaries instead of yml files. You will have to modify the task and dataset dictionaries to suit the ASE dataset (just as you have done for the task and dataset sections of the yml file).

Thank you very much. I have a question about how I’m going to freeze a parameter for a layer, I’m trying to fine-tune a model, but I can’t find where to set param.requires_grad, and I’m curious about how to freeze the weight parameter.