Git Product home page Git Product logo

Comments (4)

heyfavour avatar heyfavour commented on August 27, 2024

me too it's normal in linuxใ€‚but i run it in windows ๏ผŒit will raise RuntimeError: Failed to build object with prefix dataset using builder NpzDataset

from nequip.

Linux-cpp-lisp avatar Linux-cpp-lisp commented on August 27, 2024

This error could come from a lot of different root causes, can you please post the rest of the error message, even if Windows was the cause, for future reference?

from nequip.

Quicken90905 avatar Quicken90905 commented on August 27, 2024

I am using Ubuntu 20.04, on Windows 10 I wasn't able to get this far and after seeing this issue decided not to continue with Windows. First, the error was caused by the lack of a r_max variable in the yaml file, but after adding it as r_max: 4 the error still presists:

nequip-train test.yaml
Torch device: cpu
Processing dataset...
multiprocessing.pool.RemoteTraceback: 
"""
Traceback (most recent call last):
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/multiprocessing/pool.py", line 121, in worker
    result = (True, func(*args, **kwds))
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/multiprocessing/pool.py", line 44, in mapstar
    return list(map(*args))
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 790, in _ase_dataset_reader
    if global_index in include_frames
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/AtomicData.py", line 449, in from_ase
    **add_fields,
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/AtomicData.py", line 330, in from_points
    return cls(edge_index=edge_index, pos=torch.as_tensor(pos), **kwargs)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/AtomicData.py", line 225, in __init__
    _process_dict(kwargs)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/AtomicData.py", line 155, in _process_dict
    kwargs[k] = v.unsqueeze(-1)
AttributeError: 'numpy.int64' object has no attribute 'unsqueeze'
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/utils/auto_init.py", line 232, in instantiate
    instance = builder(**positional_args, **final_optional_args)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 887, in __init__
    type_mapper=type_mapper,
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 166, in __init__
    super().__init__(root=root, type_mapper=type_mapper)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 50, in __init__
    super().__init__(root=root, transform=type_mapper)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/utils/torch_geometric/dataset.py", line 91, in __init__
    self._process()
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/utils/torch_geometric/dataset.py", line 176, in _process
    self.process()
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 218, in process
    data = self.get_data()
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/dataset.py", line 964, in get_data
    datas = p.map(reader, list(range(n_proc)))
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/multiprocessing/pool.py", line 268, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/multiprocessing/pool.py", line 657, in get
    raise self._value
AttributeError: 'numpy.int64' object has no attribute 'unsqueeze'

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/lukas/anaconda3/envs/soc/bin/nequip-train", line 10, in <module>
    sys.exit(main())
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/scripts/train.py", line 72, in main
    trainer = fresh_start(config)
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/scripts/train.py", line 148, in fresh_start
    dataset = dataset_from_config(config, prefix="dataset")
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/data/_build.py", line 82, in dataset_from_config
    optional_args=config,
  File "/home/lukas/anaconda3/envs/soc/lib/python3.7/site-packages/nequip/utils/auto_init.py", line 236, in instantiate
    ) from e
RuntimeError: Failed to build object with prefix `dataset` using builder `ASEDataset`

from nequip.

heyfavour avatar heyfavour commented on August 27, 2024

my error caused by that handle of tmp file not released,in your code ,you rename tmp file but something is different in windows. so it cause error,but it's normal in linux

in win11
install miniconda ;install python 3.8 ; pip install nequip ;
then run your demo you can reproducing errors

from nequip.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.