Giter VIP home page Giter VIP logo

pyzfs's People

Contributors

danielskatz avatar enchantedland avatar hema-ted avatar malramsay64 avatar mgovoni-devel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

pyzfs's Issues

[review] Seemingly unfinished tasks

In the main.py and the qeoader.py files there are TODO items. There is also a commented out deprecated loader for hdf5 files.

  • The qeloader.py TODO, appears to be a performance improvement. It is completely fine to have this in a future release so this is fine.
  • The TODO items in the main.py file need addressing in some way.
  • The deprecated loader code should either have some function (test new and old the same, used under load_deprecated, ...) or be deleted rather than commented out.

[review] Instructions for running the examples

  • Instructions for running the example, which I think is bash run.sh
  • Details of the expected output. I assume that D and Ref D being the same is a good thing, however there should be some explanation of this.

A good place to put this is a README file in either each individual example directory, or one in the examples directory explaining all of them.

Some Question when running PyZFS

Hi,
I have some mistakes when running PyZFS.
When I tried the example of NV-hdf5, the code was running successfully.
But when I tried my SiV-hdf5 (63 atoms), it stopped and showed:
image
I don't konw why it happened, and I hope I can get reply from you.

[review] Improvements to installation instructions

Hi @hema-ted,

I am working through the installation steps and there are a few points which require clarification in the documentation.

  • The documentation notes that legacy versions of ase are required for python 2, there needs to be a version number known to work with python 2.
  • The note about python compatibility, and that python is required for installation should probably be at the start of the installation guide since it needs to be set up at the start of the process.
  • Include minor version numbers in the python versions supported, for example python 2.7 and python 3.5+

[review] Running unit tests

I would like to see the documentation mention the unit tests you have written and how to run them. Something like

Tests

There are some unit tests to check functionality which can be run using

python -m unittest

Additionally the examples directory has examples that check the correct working of this software.

Use entry point for command line interaction

I will just note that this isn't a requirement of acceptance of the review, and more an easy improvement I noticed.

In the setup.py file it is possible to specify an entry_point, that is adding an executable to the path which points to a function through the console_scripts entry point. This article describes everything in more detail and the setuptools documentation also includes a description of using this functionality.

This allows for using runzfs instead of python -m pyzfs.exec.runzfs and removes the need to update the PYTHON_PATH environment variable. An example of the changes required while keeping backwards compatibility are in #2. There are additional updates to the documentation which would be required if you see this change as helpful.

[REVIEW] pip does not copy subpackages

Hi @hema-ted, I am naively following the recommended installation method. After I successfully installed pyzfs with pip install ., I encountered the following error when I tried to run the program:

% pyzfs --wfcfmt qbox --filename /Users/xwang/Programs/pyzfs/pyzfs/examples/o2_qbox_xml/o2.xml
Traceback (most recent call last):
  File "/Users/xwang/anaconda3/bin/pyzfs", line 5, in <module>
    from pyzfs.run import main
  File "/Users/xwang/anaconda3/lib/python3.6/site-packages/pyzfs/run.py", line 8, in <module>
    from .common.misc import parse_sys_argv
ModuleNotFoundError: No module named 'pyzfs.common'

From what I know, pip install . copies your local packages to site-packages and install from there. But it only copies those folders that are explicitly specified in the packages argument of setup(). Since packages=["pyzfs"], the subpackages of pyzfs were not copied.

Of course one can avoid my mistake by add the pyzfs source folder to PYTHONPATH. Or, you can save this step by either:

  • change your packages to include explicitly the subpackages like pyzfs.common, pyzfs.common.wfc, etc., or
  • use packages=find_packages() in setup(). This will automatically include all folders that contain the __init__.py file. And this will be especially useful if your program becomes large.

[review] How to run diamond_nv_qe_hdf5 example

To run this example I need to install and run Quantum Espresso.

  • There should be a link to installing quantum espresso with the required options.
  • The command required to generate the dataset needs to be documented somewhere.

See also #4

Handling G = [0.0, 0.0, 0.0]

Hi @hema-ted

From what I can tell from the code, the contribution to the accumulation over G-vectors just ignores the contribution at G =[0.0, 0.0, 0.0].

I know that this done to avoid the singularity in the expression (dividing by zero), but I am not sure this just warrants ignoring the term.

Do we have any justification for this?

Exec module gives SyntaxError when using python2

When attempting to run the pyzfs command line on python2 I get a SyntaxError.

This is because exec is a statement in python2, having more rules about it's use which are not present in python3, where it works fine.

A fix would be changing the name of the exec module.

Issue in diamond_nv_qe_hdf5 example

Dear Authors,
I followed the instructions to run the diamond_nv_qe_hdf5 example. The first step to run QE to generate wavefunction seemed fine. However, when I run the second step (mpirun pyzfs --wfcfmt qeh5 > zfs.out), I met a bug:

Traceback (most recent call last):
File "/home/linzz/anaconda3/lib/python3.6/site-packages/h5py/_hl/files.py", line 121, in make_fid
fid = h5f.open(name, h5f.ACC_RDWR, fapl=fapl)
File "h5py/_objects.pyx", line 54, in h5py._objects.with_phil.wrapper
File "h5py/_objects.pyx", line 55, in h5py._objects.with_phil.wrapper
File "h5py/h5f.pyx", line 78, in h5py.h5f.open
OSError: Unable to open file (Unable to lock file, errno = 11, error message = 'resource temporarily unavailable')

Besides, I met some warnings simultaneously, which reads:

/home/linzz/anaconda3/lib/python3.6/site-packages/ase/utils/init.py:41: FutureWarning: Please use atoms.cell.reciprocal()
warnings.warn(warning)

Could you please give me any suggestions to solve these problems?
Thank you very much.

Yours sincerely
Zz Lin

Is direct wavefunction analysis meaningful?

Hi,

I noticed the pyzfs package is based on wavefunction analysis, hence I post my following question relevant to wavefunction analysis. See following for more info.

See the notes from here, as shown below:

The wave function has no direct physical meaning.  It is just one way
of storing information.  It stores all the information available to
the observer about the system.  To make predictions about the outcome
of all measurements, at any time, one has to "do" something to the
wave function to extract information.  One has to perform some
mathematical operation on it, such a squaring it, multiplying it by a
constant, differentiating it, etc.  One has to operate on the wave
function with some operator.  (The operator is a specific instruction
or set of instructions.)  Every observable is associated with its own
operator.

I want to know whether it really makes sense to analyze the real or imaginary parts of a wavefunction directly.

Regards,
HY

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.