Giter VIP home page Giter VIP logo

Comments (5)

ridderl avatar ridderl commented on May 24, 2024

I fixed this issue by introducing the special Settings keyword "__block _replace"

__block_replace = True

results in removing all existing key value pairs in the current node of the settings tree.

For example:

from qmworks import Settings
t = Settings()
t.input.xc.lda = ""
u = Settings()
u.input.xc.hybrid = 'b3lyp'
print(t.overlay(u))

        input:
              xc:
                 hybrid:     b3lyp
                 lda:

u.input.xc.__block_replace = True
print(t.overlay(u))

        input:
              xc:
                 __block_replace:     True
                 hybrid:     b3lyp

I added the __block_replace keyword already in the templates, so you don't need to add __block_replace to your user settings. It should just work know. Please try and let me know if you encounter any issues.

from qmflows.

ridderl avatar ridderl commented on May 24, 2024

By the way: these recent changes are currently only in the "develop" branch of qmworks

from qmflows.

sgu800 avatar sgu800 commented on May 24, 2024

Dear Lars,

I have tested it and I got a following error "RuntimeError: dictionary changed size during iteration"., which is related to templates.
slurm-2272394.txt

Kind regards,
Satesh

from qmflows.

ridderl avatar ridderl commented on May 24, 2024

Hi Satesh,

I cannot reproduce this problem, which your reported quite some time ago. Is it still occurring on your side?

Regards,
Lars

from qmflows.

sgu800 avatar sgu800 commented on May 24, 2024

Dear Lars,

I have tested them again and it is not occurring now.

Regards,
Satesh

from qmflows.

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.