[ALPS-users] Maybe a DataSet.props bug for ALPS MPS Project
Michele Dolfi
michele.dolfi at gmail.com
Sun Dec 17 10:46:32 CET 2017
Hello,
Thanks for reporting this behavior.
We started investigating it a bit and it doesn’t seem to be related to the MPS applications, but to the ALPS Parameters class.
Attached is a small test.
Just running "h5dump test.h5” shows the buggy output.
--
Michele
> On 13 Dec 2017, at 10:02, Rongyang Sun <sun-rongyang at outlook.com> wrote:
>
> Dear all,
>
> I found an interesting wrong var assignment in ALPS MPS Project version: MAQUIS repo r4143 (2013-2014). It appears both on OSX bmg package version and builds from source code version on Linux. You can use the following simple script to reappear the problem:
>
> ********************************************************
> #
> # Author: Rongyang Sun <sun-rongyang at outlook.com <mailto:sun-rongyang at outlook.com>>
> # Date: 2017-12-13 11:59
> # Last Modified Date: 2017-12-13 11:59
> # Last Modified By: Rongyang Sun <sun-rongyang at outlook.com <mailto:sun-rongyang at outlook.com>>
> #
> # Description: A demo to show the interesting bug
> #
>
> import pyalps
>
> #prepare the input parameters
> parms = [ {
> 'LATTICE' : "open chain lattice",
> 'MODEL' : "spin",
> 'CONSERVED_QUANTUMNUMBERS' : 'N,Sz',
> 'Sz_total' : 0,
> 'J' : 1,
> 'spin' : 1,
> 'SWEEPS' : 4,
> 'NUMBER_EIGENVALUES' : 1,
> 'L' : 10,
> 'MAXSTATES' : 100
> } ]
>
> input_file = pyalps.writeInputFiles('bug',parms)
> res = pyalps.runApplication('mps_optim',input_file,writexml=True)
> data = pyalps.loadEigenstateMeasurements(pyalps.getResultFiles(prefix='bug'),verbose=True)
>
> print("\nMODEL: {0}".format(str(data[0][0].props['MODEL'])))
>
> ********************************************************
>
> It will return "MODEL: 1" not the right "MODEL" parameter because I define an unused parameter 'spin' with value 1. Once a parameter with a name which appears at the value of 'MODEL', it will be replaced by the value of the parameter. It is more severe for 't-J' model case. if you set 't': 1.0 and 'J': 0.5, 'MODEL' will be assigned as 0.5 which equals 1.0('t') - 0.5('J')! I have checked the output hdf5 file and found that the wrong replace had happened in the file. That means it may be a bug about ALPS MPS code.
>
> Best regards,
> Rongyang Sun
>
>
> ----
> Comp-phys-alps-users Mailing List for the ALPS Project
> http://alps.comp-phys.org/ <http://alps.comp-phys.org/>
>
> List info: https://lists.phys.ethz.ch//listinfo/comp-phys-alps-users <https://lists.phys.ethz.ch//listinfo/comp-phys-alps-users>
> Archive: https://lists.phys.ethz.ch//pipermail/comp-phys-alps-users <https://lists.phys.ethz.ch//pipermail/comp-phys-alps-users>
>
> Unsubscribe by writing a mail to comp-phys-alps-users-leave at lists.phys.ethz.ch <mailto:comp-phys-alps-users-leave at lists.phys.ethz.ch>.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.phys.ethz.ch/pipermail/comp-phys-alps-users/attachments/20171217/cb81b471/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: main.cpp
Type: application/octet-stream
Size: 411 bytes
Desc: not available
URL: <https://lists.phys.ethz.ch/pipermail/comp-phys-alps-users/attachments/20171217/cb81b471/attachment.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.phys.ethz.ch/pipermail/comp-phys-alps-users/attachments/20171217/cb81b471/attachment-0001.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Makefile
Type: application/octet-stream
Size: 207 bytes
Desc: not available
URL: <https://lists.phys.ethz.ch/pipermail/comp-phys-alps-users/attachments/20171217/cb81b471/attachment-0001.obj>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.phys.ethz.ch/pipermail/comp-phys-alps-users/attachments/20171217/cb81b471/attachment-0002.html>
More information about the Comp-phys-alps-users
mailing list