Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
  • N NIFTy
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 19
    • Issues 19
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 12
    • Merge requests 12
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • ift
  • NIFTy
  • Issues
  • #70
Closed
Open
Issue created Apr 06, 2017 by Pumpe, Daniel (dpumpe)@dpumpe

create_power_operator

Hi Theo, while checking volume factors in my code I stumbled over a potential bug in sugar.py create_power_operator. In line 27 the DiagonalOperator should be bare=True (default is False). Else wise the application of such a "PowerOperator" does not match the results as if the code would be run in Nifty 1. Or am I missing something, please correct me if I see something wrong.

Power Spectrum differences

NIFTY_1

x1 = rg_space(200, zerocenter=False, dist=0.1) k1 = x1.get_codomain()

spec1 = (lambda k: 42/(1+k**2)) S1 = power_operator(k1, spec=spec1)

test1 = field(x1, val=3)

result1 = S1.inverse_times(test1)

NIFTy_3

x3 = RGSpace(200, zerocenter=False, distances=0.1) k3 = RGRGTransformation.get_codomain(x3)

spec3 = (lambda k:42/(1+k**2)) S3 = create_power_operator(k3, spec3) FFT3 = FFTOperator(domain=x3, target=k3, domain_dtype=np.float64, target_dtype=np.complex64)

test3 = Field(x3, val=3)

result3 = FFT3.inverse_times(S3.inverse_times(FFT3.times(test3)))

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking