From 83400bbed680800a301304b5dfd81a454df09dca Mon Sep 17 00:00:00 2001 From: Martin Reinecke <martin@mpa-garching.mpg.de> Date: Thu, 5 Jul 2018 10:47:23 +0200 Subject: [PATCH] update docs, more imports --- docs/source/code.rst | 11 +++++------ nifty5/__init__.py | 2 +- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/docs/source/code.rst b/docs/source/code.rst index fc4ba5071..80c1e348e 100644 --- a/docs/source/code.rst +++ b/docs/source/code.rst @@ -142,12 +142,11 @@ There is also a set of convenience functions to generate fields with constant values or fields filled with random numbers according to a user-specified distribution. -Fields are the only fundamental NIFTy objects which can change state after they -have been constructed: while their data type, domain, and array shape cannot -be modified, the actual data content of the array may be manipulated during the -lifetime of the object. This is a slight deviation from the philosophy that all -NIFTy objects should be immutable, but this choice offers considerable -performance benefits. +Like almost all NIFTy objects, fields are immutable: their value or any other +attribute cannot be modified after construction. To manipulate a field in ways +that are not covered by the provided standard operations, its data content must +be extracted first, then changed, and a new field has to be created from the +result. Linear Operators diff --git a/nifty5/__init__.py b/nifty5/__init__.py index 04e19aa4e..5a2c94c78 100644 --- a/nifty5/__init__.py +++ b/nifty5/__init__.py @@ -89,7 +89,7 @@ from .library.bernoulli_energy import BernoulliEnergy from . import extra -from .utilities import memo +from .utilities import memo, frozendict from .logger import logger -- GitLab