pyALF 2.6.post35__tar.gz → 2.6.post40__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (37) hide show
  1. {pyalf-2.6.post35/pyALF.egg-info → pyalf-2.6.post40}/PKG-INFO +1 -3
  2. {pyalf-2.6.post35 → pyalf-2.6.post40/pyALF.egg-info}/PKG-INFO +1 -3
  3. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyALF.egg-info/requires.txt +0 -3
  4. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/analysis.py +34 -24
  5. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_postprocess.py +5 -1
  6. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyproject.toml +0 -1
  7. {pyalf-2.6.post35 → pyalf-2.6.post40}/LICENSE +0 -0
  8. {pyalf-2.6.post35 → pyalf-2.6.post40}/MANIFEST.in +0 -0
  9. {pyalf-2.6.post35 → pyalf-2.6.post40}/README.md +0 -0
  10. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyALF.egg-info/SOURCES.txt +0 -0
  11. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyALF.egg-info/dependency_links.txt +0 -0
  12. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyALF.egg-info/entry_points.txt +0 -0
  13. {pyalf-2.6.post35 → pyalf-2.6.post40}/pyALF.egg-info/top_level.txt +0 -0
  14. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/__init__.py +0 -0
  15. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/alf_source.py +0 -0
  16. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/ana.py +0 -0
  17. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/check_common.py +0 -0
  18. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/check_rebin_ipy.py +0 -0
  19. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/check_rebin_tk.py +0 -0
  20. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/check_warmup_ipy.py +0 -0
  21. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/check_warmup_tk.py +0 -0
  22. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/__init__.py +0 -0
  23. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_bin_count.py +0 -0
  24. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_del_bins.py +0 -0
  25. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_run.py +0 -0
  26. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_show_obs.py +0 -0
  27. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/alf_test_branch.py +0 -0
  28. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/cli/minimal_ALF_run.py +0 -0
  29. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/exceptions.py +0 -0
  30. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/init_layout.py +0 -0
  31. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/lattice.py +0 -0
  32. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/lattices_armv8.4-a.so +0 -0
  33. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/lattices_x86-64.so +0 -0
  34. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/simulation.py +0 -0
  35. {pyalf-2.6.post35 → pyalf-2.6.post40}/py_alf/utils.py +0 -0
  36. {pyalf-2.6.post35 → pyalf-2.6.post40}/setup.cfg +0 -0
  37. {pyalf-2.6.post35 → pyalf-2.6.post40}/tests/test_lattice_init.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyALF
3
- Version: 2.6.post35
3
+ Version: 2.6.post40
4
4
  Summary: Python interface for ALF, plus scripts and Jupyter notebooks.
5
5
  Author-email: ALF Collaboration <alf@physik.uni-wuerzburg.de>, Jonas Schwab <jonas.schwab@uni-wuerzburg.de>
6
6
  License-Expression: GPL-2.0-or-later
@@ -22,8 +22,6 @@ Requires-Dist: numba
22
22
  Requires-Dist: numpy
23
23
  Requires-Dist: pandas
24
24
  Requires-Dist: scipy
25
- Provides-Extra: gui
26
- Requires-Dist: tkinter; extra == "gui"
27
25
  Provides-Extra: doc
28
26
  Requires-Dist: sphinxcontrib-svg2pdfconverter; extra == "doc"
29
27
  Requires-Dist: jupyter-book<2.0; extra == "doc"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyALF
3
- Version: 2.6.post35
3
+ Version: 2.6.post40
4
4
  Summary: Python interface for ALF, plus scripts and Jupyter notebooks.
5
5
  Author-email: ALF Collaboration <alf@physik.uni-wuerzburg.de>, Jonas Schwab <jonas.schwab@uni-wuerzburg.de>
6
6
  License-Expression: GPL-2.0-or-later
@@ -22,8 +22,6 @@ Requires-Dist: numba
22
22
  Requires-Dist: numpy
23
23
  Requires-Dist: pandas
24
24
  Requires-Dist: scipy
25
- Provides-Extra: gui
26
- Requires-Dist: tkinter; extra == "gui"
27
25
  Provides-Extra: doc
28
26
  Requires-Dist: sphinxcontrib-svg2pdfconverter; extra == "doc"
29
27
  Requires-Dist: jupyter-book<2.0; extra == "doc"
@@ -8,9 +8,6 @@ numpy
8
8
  pandas
9
9
  scipy
10
10
 
11
- [GUI]
12
- tkinter
13
-
14
11
  [doc]
15
12
  sphinxcontrib-svg2pdfconverter
16
13
  jupyter-book<2.0
@@ -1,5 +1,7 @@
1
1
  """Supplies the default analysis routine."""
2
2
  # pylint: disable=invalid-name
3
+ # pylint: disable=too-many-arguments
4
+ # pylint: disable=too-many-positional-arguments
3
5
 
4
6
  import os
5
7
  import pickle
@@ -23,11 +25,11 @@ from .exceptions import TooFewBinsError
23
25
 
24
26
 
25
27
  def analysis(directory,
26
- symmetry=None, custom_obs=None, do_tau=True, always=False):
28
+ symmetry=None, custom_obs=None, do_tau=True, always=False, write_plain_text=True):
27
29
  """Perform analysis in the given directory.
28
30
 
29
31
  Results are written to the pickled dictionary `res.pkl` and in plain text
30
- in the folder `res/`.
32
+ in the folder `res/` if `write_plain_text` is True.
31
33
 
32
34
  Parameters
33
35
  ----------
@@ -55,7 +57,10 @@ def analysis(directory,
55
57
  speeds up analysis and makes result files much smaller.
56
58
  always : bool, default=False
57
59
  Do not skip if parameters and bins are older than results.
58
-
60
+ write_plain_text : bool, default=True
61
+ Write results in plain text files in the `res/` folder.
62
+ Setting this to False saves disk space (in particular in terms of number of files),
63
+ but makes it harder to read results without loading the pickled dictionary `res.pkl`.
59
64
  """
60
65
  # pylint: disable=too-many-locals
61
66
  # pylint: disable=too-many-branches
@@ -131,7 +136,7 @@ def analysis(directory,
131
136
  list_obs.append(o)
132
137
  list_tau.append(o)
133
138
 
134
- if 'res' not in os.listdir(directory):
139
+ if write_plain_text and 'res' not in os.listdir(directory):
135
140
  os.mkdir(os.path.join(directory, 'res'))
136
141
 
137
142
  dic = params
@@ -158,10 +163,11 @@ def analysis(directory,
158
163
  dic[obs_name] = dat[0]
159
164
  dic[obs_name+'_err'] = dat[1]
160
165
 
161
- np.savetxt(
162
- os.path.join(directory, 'res', obs_name),
163
- dat
164
- )
166
+ if write_plain_text:
167
+ np.savetxt(
168
+ os.path.join(directory, 'res', obs_name),
169
+ dat
170
+ )
165
171
 
166
172
  print("Scalar observables:")
167
173
  for obs_name in list_scal:
@@ -178,11 +184,12 @@ def analysis(directory,
178
184
  dic[obs_name+str(i)] = dat[i, 0]
179
185
  dic[obs_name+str(i)+'_err'] = dat[i, 1]
180
186
 
181
- np.savetxt(
182
- os.path.join(directory, 'res', obs_name),
183
- dat,
184
- header='Sign: {} {}'.format(*sign)
185
- )
187
+ if write_plain_text:
188
+ np.savetxt(
189
+ os.path.join(directory, 'res', obs_name),
190
+ dat,
191
+ header='Sign: {} {}'.format(*sign)
192
+ )
186
193
 
187
194
  print("Histogram observables:")
188
195
  for obs_name in list_hist:
@@ -202,12 +209,13 @@ def analysis(directory,
202
209
  hist['lower'] = lower
203
210
  dic[obs_name] = hist
204
211
 
205
- np.savetxt(
206
- os.path.join(directory, 'res', obs_name),
207
- dat,
208
- header='Sign: {} {}, above {} {}, below {} {}'.format(
209
- *sign, *above, *below)
210
- )
212
+ if write_plain_text:
213
+ np.savetxt(
214
+ os.path.join(directory, 'res', obs_name),
215
+ dat,
216
+ header='Sign: {} {}, above {} {}, below {} {}'.format(
217
+ *sign, *above, *below)
218
+ )
211
219
 
212
220
  print("Equal time observables:")
213
221
  for obs_name in list_eq:
@@ -219,9 +227,10 @@ def analysis(directory,
219
227
  print("Too few bins, skipping.")
220
228
  continue
221
229
 
222
- write_res_eq(directory, obs_name,
223
- m_k, e_k, m_k_sum, e_k_sum,
224
- m_r, e_r, m_r_sum, e_r_sum, latt)
230
+ if write_plain_text:
231
+ write_res_eq(directory, obs_name,
232
+ m_k, e_k, m_k_sum, e_k_sum,
233
+ m_r, e_r, m_r_sum, e_r_sum, latt)
225
234
 
226
235
  dic[obs_name+'K'] = m_k
227
236
  dic[obs_name+'K_err'] = e_k
@@ -249,8 +258,9 @@ def analysis(directory,
249
258
  print("Too few bins, skipping.")
250
259
  continue
251
260
 
252
- write_res_tau(directory, obs_name,
253
- m_k, e_k, m_r, e_r, dtau, latt)
261
+ if write_plain_text:
262
+ write_res_tau(directory, obs_name,
263
+ m_k, e_k, m_r, e_r, dtau, latt)
254
264
 
255
265
  dic[obs_name+'K'] = m_k
256
266
  dic[obs_name+'K_err'] = e_k
@@ -56,6 +56,9 @@ def _get_arg_parser():
56
56
  help='File that defines lattice symmetries. '
57
57
  'This file has to define the object symmetry, '
58
58
  'needed by py_alf.analysis. (default: None))')
59
+ parser.add_argument(
60
+ '--no_plain_text', action="store_true",
61
+ help='Skip writing plain text results in folder "res".')
59
62
  parser.add_argument(
60
63
  'directories', nargs='*',
61
64
  help='Directories to analyze. If empty, analyzes all '
@@ -109,7 +112,8 @@ def _main():
109
112
  if args.do_analysis:
110
113
  for directory in directories:
111
114
  analysis(directory, custom_obs=custom_obs, symmetry=symmetry,
112
- do_tau=not args.no_tau, always=args.always)
115
+ do_tau=not args.no_tau,
116
+ write_plain_text=not args.no_plain_text, always=args.always)
113
117
 
114
118
  if args.gather:
115
119
  df = load_res(directories)
@@ -38,7 +38,6 @@ dependencies = [
38
38
  ]
39
39
 
40
40
  [project.optional-dependencies]
41
- GUI = ["tkinter"]
42
41
  doc = [
43
42
  "sphinxcontrib-svg2pdfconverter",
44
43
  "jupyter-book<2.0",
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes