pycistem 0.7__py3-none-any.whl

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 (41) hide show
  1. pycistem/__init__.py +9 -0
  2. pycistem/config.py +20 -0
  3. pycistem/core/__init__.py +11 -0
  4. pycistem/core/core.cpp +1070 -0
  5. pycistem/core/database.cpp +408 -0
  6. pycistem/core/euler_search.cpp +72 -0
  7. pycistem/core/run_profiles.cpp +114 -0
  8. pycistem/database/__init__.py +300 -0
  9. pycistem/programs/__init__.py +10 -0
  10. pycistem/programs/_cistem_constants.py +23 -0
  11. pycistem/programs/apply_ctf.py +59 -0
  12. pycistem/programs/cistem_program.py +277 -0
  13. pycistem/programs/ctffind.py +254 -0
  14. pycistem/programs/estimate_beamtilt.py +60 -0
  15. pycistem/programs/match_template.py +326 -0
  16. pycistem/programs/reconstruct3d.py +79 -0
  17. pycistem/programs/refine_ctf.py +106 -0
  18. pycistem/programs/refine_template.py +157 -0
  19. pycistem/programs/refine_template_dev.py +35 -0
  20. pycistem/programs/refine_template_niko.py +124 -0
  21. pycistem/programs/resample.py +30 -0
  22. pycistem/programs/run_profile.py +17 -0
  23. pycistem/programs/unblur.py +247 -0
  24. pycistem/programs/unblur_patch.py +235 -0
  25. pycistem/pycore/PLAN.md +96 -0
  26. pycistem/pycore/__init__.py +20 -0
  27. pycistem/pycore/_database.py +183 -0
  28. pycistem/pycore/_euler_search.py +227 -0
  29. pycistem/pycore/_project.py +119 -0
  30. pycistem/pycore/_run_profiles.py +240 -0
  31. pycistem/utils/__init__.py +1 -0
  32. pycistem/utils/extract_particles.py +36 -0
  33. pycistem/utils/move_class_into_unbinned_particle_stack.py +34 -0
  34. pycistem/utils/order_by_class_occupancy.py +26 -0
  35. pycistem/utils/plot_class_occupancy.py +51 -0
  36. pycistem/utils/plot_classification_fsc_movie.py +90 -0
  37. pycistem/utils/plot_occupancy_by_condition.py +129 -0
  38. pycistem-0.7.dist-info/METADATA +257 -0
  39. pycistem-0.7.dist-info/RECORD +41 -0
  40. pycistem-0.7.dist-info/WHEEL +4 -0
  41. pycistem-0.7.dist-info/licenses/LICENSE +201 -0
pycistem/__init__.py ADDED
@@ -0,0 +1,9 @@
1
+ __version__ = "0.7"
2
+
3
+ #from . import core
4
+ from pycistem import database, programs, utils
5
+ from pycistem.config import set_cistem_path
6
+
7
+
8
+
9
+
pycistem/config.py ADDED
@@ -0,0 +1,20 @@
1
+ from pathlib import Path
2
+
3
+ import appdirs
4
+ import yaml
5
+
6
+ config = {
7
+ "CISTEM_PATH": "/usr/local/bin/"
8
+ }
9
+ config_path = Path(appdirs.user_config_dir("pycistem","cistem")) / "config.yaml"
10
+ if config_path.exists():
11
+ with open(config_path) as fp:
12
+ config_file = yaml.safe_load(fp)
13
+ if "CISTEM_PATH" in config:
14
+ config["CISTEM_PATH"] = config_file["CISTEM_PATH"]
15
+
16
+ def set_cistem_path(path):
17
+ config["CISTEM_PATH"] = path
18
+ config_path.parent.mkdir(parents=True,exist_ok=True)
19
+ with open(config_path,"w") as fp:
20
+ yaml.dump(config,fp)
@@ -0,0 +1,11 @@
1
+ try:
2
+ from pycistem.core.core import *
3
+ except ImportError:
4
+ import warnings
5
+ warnings.warn(
6
+ "pycistem.core C++ extension is not available. "
7
+ "Functionality requiring core (EulerSearch, ParameterMap, Project, etc.) will raise ImportError. "
8
+ "To build with core support, ensure cisTEM, wxWidgets, and FFTW are installed, then reinstall pycistem from source.",
9
+ ImportWarning,
10
+ stacklevel=2,
11
+ )