atomict 0.1.4__tar.gz → 0.2.4__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 (86) hide show
  1. {atomict-0.1.4 → atomict-0.2.4}/PKG-INFO +7 -3
  2. {atomict-0.1.4 → atomict-0.2.4}/README.md +3 -0
  3. atomict-0.2.4/atomict/__version__.py +1 -0
  4. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/upload.py +8 -3
  5. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/main.py +9 -3
  6. {atomict-0.1.4 → atomict-0.2.4}/atomict/io/cif.py +9 -2
  7. {atomict-0.1.4 → atomict-0.2.4}/atomict/io/fhiaims.py +8 -2
  8. {atomict-0.1.4 → atomict-0.2.4}/atomict/io/json.py +8 -2
  9. atomict-0.2.4/atomict/simulation/mattergen.py +20 -0
  10. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/utils.py +9 -2
  11. {atomict-0.1.4 → atomict-0.2.4}/atomict/utils/fhiaims/geometry.py +12 -4
  12. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/PKG-INFO +7 -3
  13. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/SOURCES.txt +1 -0
  14. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/requires.txt +4 -2
  15. {atomict-0.1.4 → atomict-0.2.4}/pyproject.toml +2 -0
  16. atomict-0.2.4/requirements.txt +8 -0
  17. atomict-0.1.4/atomict/__version__.py +0 -1
  18. atomict-0.1.4/requirements.txt +0 -10
  19. {atomict-0.1.4 → atomict-0.2.4}/LICENSE +0 -0
  20. {atomict-0.1.4 → atomict-0.2.4}/atomict/__init__.py +0 -0
  21. {atomict-0.1.4 → atomict-0.2.4}/atomict/api.py +0 -0
  22. {atomict-0.1.4 → atomict-0.2.4}/atomict/auth.py +0 -0
  23. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/__init__.py +0 -0
  24. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/adsorbate.py +0 -0
  25. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/ai_assist.py +0 -0
  26. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/catalysis.py +0 -0
  27. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/common.py +0 -0
  28. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/exploration/__init__.py +0 -0
  29. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/exploration/soec.py +0 -0
  30. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/exploration/sqs.py +0 -0
  31. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/helpers.py +0 -0
  32. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/k8s.py +0 -0
  33. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/login.py +0 -0
  34. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/organization.py +0 -0
  35. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/project.py +0 -0
  36. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation/__init__.py +0 -0
  37. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation/catalysis.py +0 -0
  38. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation/fhiaims.py +0 -0
  39. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation/kpoint.py +0 -0
  40. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation/vibes.py +0 -0
  41. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/simulation.py +0 -0
  42. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/task.py +0 -0
  43. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/commands/user.py +0 -0
  44. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/core/client.py +0 -0
  45. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/core/config.py +0 -0
  46. {atomict-0.1.4 → atomict-0.2.4}/atomict/cli/core/utils.py +0 -0
  47. {atomict-0.1.4 → atomict-0.2.4}/atomict/env.py +0 -0
  48. {atomict-0.1.4 → atomict-0.2.4}/atomict/exceptions.py +0 -0
  49. {atomict-0.1.4 → atomict-0.2.4}/atomict/infra/__init__.py +0 -0
  50. {atomict-0.1.4 → atomict-0.2.4}/atomict/infra/distwork/__init__.py +0 -0
  51. {atomict-0.1.4 → atomict-0.2.4}/atomict/infra/distwork/environment.py +0 -0
  52. {atomict-0.1.4 → atomict-0.2.4}/atomict/infra/distwork/task.py +0 -0
  53. {atomict-0.1.4 → atomict-0.2.4}/atomict/infra/logging.py +0 -0
  54. {atomict-0.1.4 → atomict-0.2.4}/atomict/io/__init__.py +0 -0
  55. {atomict-0.1.4 → atomict-0.2.4}/atomict/io/utils.py +0 -0
  56. {atomict-0.1.4 → atomict-0.2.4}/atomict/ml/__init__.py +0 -0
  57. {atomict-0.1.4 → atomict-0.2.4}/atomict/ml/model.py +0 -0
  58. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/__init__.py +0 -0
  59. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/link.py +0 -0
  60. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/note.py +0 -0
  61. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/project.py +0 -0
  62. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/tags.py +0 -0
  63. {atomict-0.1.4 → atomict-0.2.4}/atomict/project/workbench.py +0 -0
  64. {atomict-0.1.4 → atomict-0.2.4}/atomict/reality/__init__.py +0 -0
  65. {atomict-0.1.4 → atomict-0.2.4}/atomict/reality/oqmd.py +0 -0
  66. {atomict-0.1.4 → atomict-0.2.4}/atomict/reality/slabs.py +0 -0
  67. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/__init__.py +0 -0
  68. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/cantera.py +0 -0
  69. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/catalysis.py +0 -0
  70. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/counterfactual.py +0 -0
  71. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/ea.py +0 -0
  72. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/fhi_aims.py +0 -0
  73. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/kpoint.py +0 -0
  74. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/mlrelax.py +0 -0
  75. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/phonon.py +0 -0
  76. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/qe.py +0 -0
  77. {atomict-0.1.4 → atomict-0.2.4}/atomict/simulation/sqs.py +0 -0
  78. {atomict-0.1.4 → atomict-0.2.4}/atomict/user/__init__.py +0 -0
  79. {atomict-0.1.4 → atomict-0.2.4}/atomict/user/files.py +0 -0
  80. {atomict-0.1.4 → atomict-0.2.4}/atomict/user/workspace.py +0 -0
  81. {atomict-0.1.4 → atomict-0.2.4}/atomict/utils/fhiaims/__init__.py +0 -0
  82. {atomict-0.1.4 → atomict-0.2.4}/atomict/utils/tenacity.py +0 -0
  83. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/dependency_links.txt +0 -0
  84. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/entry_points.txt +0 -0
  85. {atomict-0.1.4 → atomict-0.2.4}/atomict.egg-info/top_level.txt +0 -0
  86. {atomict-0.1.4 → atomict-0.2.4}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: atomict
3
- Version: 0.1.4
3
+ Version: 0.2.4
4
4
  Summary: The client application for the https://atomictessellator.com/
5
5
  Author-email: Steven Anderson <steven@atomictessellator.com>, Alain Richardt <alain@atomictessellator.com>
6
6
  License: MIT
@@ -18,12 +18,13 @@ Requires-Python: >=3.10
18
18
  Description-Content-Type: text/markdown
19
19
  License-File: LICENSE
20
20
  Requires-Dist: requests
21
- Requires-Dist: ase>=3.23.0
22
21
  Requires-Dist: tenacity~=9.0
23
- Requires-Dist: spglib==2.5.0
24
22
  Requires-Dist: httpx
25
23
  Requires-Dist: click~=8.0
26
24
  Requires-Dist: rich~=13.0
25
+ Provides-Extra: utils
26
+ Requires-Dist: ase==3.23.0; extra == "utils"
27
+ Requires-Dist: spglib==2.5.0; extra == "utils"
27
28
  Provides-Extra: dev
28
29
  Requires-Dist: pytest~=8.0; extra == "dev"
29
30
  Requires-Dist: black; extra == "dev"
@@ -36,6 +37,9 @@ Requires-Dist: flake8; extra == "dev"
36
37
  ## Installation
37
38
  ```
38
39
  pip install atomict
40
+
41
+ # install utils package with scientific extensions (ase, spglib)
42
+ pip install atomict[utils]
39
43
  ```
40
44
 
41
45
  ## Installation for devs
@@ -3,6 +3,9 @@
3
3
  ## Installation
4
4
  ```
5
5
  pip install atomict
6
+
7
+ # install utils package with scientific extensions (ase, spglib)
8
+ pip install atomict[utils]
6
9
  ```
7
10
 
8
11
  ## Installation for devs
@@ -0,0 +1 @@
1
+ __version__ = "0.2.4"
@@ -53,8 +53,9 @@ def upload():
53
53
  @click.option("--limit", type=int, help="Number of results to return")
54
54
  @click.option("--type", "file_type", help="Filter by file type")
55
55
  @click.option("--json-output", is_flag=True, help="Output in JSON format")
56
- def list(limit: Optional[int], file_type: Optional[str], json_output: bool):
57
- """List uploaded files"""
56
+ @click.option("--all", "fetch_all", is_flag=True, help="Fetch all results")
57
+ def get(limit: Optional[int], file_type: Optional[str], json_output: bool = False, fetch_all: bool = False):
58
+ """Get uploaded files"""
58
59
  params = {}
59
60
  if limit:
60
61
  params["limit"] = limit
@@ -62,7 +63,11 @@ def list(limit: Optional[int], file_type: Optional[str], json_output: bool):
62
63
  params["type"] = file_type
63
64
 
64
65
  client = get_client()
65
- results = client.get_all("/api/user-upload/", params)
66
+
67
+ if fetch_all:
68
+ results = client.get_all("/api/user-upload/", params)
69
+ else:
70
+ results = client.get("/api/user-upload/", params)
66
71
 
67
72
  if json_output:
68
73
  console.print_json(data=results)
@@ -66,17 +66,23 @@ def completion(shell):
66
66
  if shell == "bash":
67
67
  completion_script = """
68
68
  # Add to ~/.bashrc:
69
- eval "$(_AT_COMPLETE=bash_source at)"
69
+ if at -v > /dev/null 2>&1; then
70
+ eval "$(_AT_COMPLETE=bash_source at)"
71
+ fi
70
72
  """
71
73
  elif shell == "zsh":
72
74
  completion_script = """
73
75
  # Add to ~/.zshrc:
74
- eval "$(_AT_COMPLETE=zsh_source at)"
76
+ if at -v > /dev/null 2>&1; then
77
+ eval "$(_AT_COMPLETE=zsh_source at)"
78
+ fi
75
79
  """
76
80
  elif shell == "fish":
77
81
  completion_script = """
78
82
  # Add to ~/.config/fish/config.fish:
79
- eval "$(_AT_COMPLETE=fish_source at)"
83
+ if at -v > /dev/null 2>&1; then
84
+ eval "$(_AT_COMPLETE=fish_source at)"
85
+ fi
80
86
  """
81
87
  click.echo(f"# Shell completion for {shell}")
82
88
  click.echo(completion_script.strip())
@@ -1,6 +1,13 @@
1
1
  import logging
2
- import ase.io
3
- import spglib
2
+
3
+ try:
4
+ import ase.io
5
+ import spglib
6
+ except ImportError:
7
+ raise ImportError(
8
+ "The 'ase' and 'spglib' packages are required for CIF operations. "
9
+ "To install the optional dependency, use atomict[utils]"
10
+ )
4
11
 
5
12
 
6
13
  class CIFAnalyzer:
@@ -1,5 +1,11 @@
1
- from ase.io.aims import check_convergence, get_aims_out_chunks, get_header_chunk
2
- from ase.utils import reader
1
+ try:
2
+ from ase.io.aims import check_convergence, get_aims_out_chunks, get_header_chunk
3
+ from ase.utils import reader
4
+ except ImportError:
5
+ raise ImportError(
6
+ "The 'ase' package is required for FHI-aims operations. "
7
+ "To install the optional dependency, use atomict[utils]"
8
+ )
3
9
 
4
10
 
5
11
  # We have to write our own function because he read_aims_output function inside ASE only supports
@@ -1,8 +1,14 @@
1
1
  import io
2
2
  import json
3
3
 
4
- from ase import Atoms
5
- from ase.io import read, write
4
+ try:
5
+ from ase import Atoms
6
+ from ase.io import read, write
7
+ except ImportError:
8
+ raise ImportError(
9
+ "The 'ase' package is required for JSON operations with Atoms objects. "
10
+ "To install the optional dependency, use atomict[utils]"
11
+ )
6
12
 
7
13
 
8
14
  def atoms_to_json(atoms: Atoms) -> str:
@@ -0,0 +1,20 @@
1
+ from atomict.api import get, post
2
+
3
+
4
+ def get_mattergen(id: str):
5
+ """
6
+ Get MatterGen
7
+ """
8
+ result = get(f"api/mattergen-exploration/{id}/")
9
+ return result
10
+
11
+
12
+ def associate_user_upload_with_mattergen(user_upload_id: str, exploration_id: str):
13
+ """
14
+ Associate a user upload with a MatterGen
15
+ """
16
+ result = post(
17
+ "api/mattergen-exploration-file/",
18
+ payload={"user_upload_id": user_upload_id, "exploration_id": exploration_id},
19
+ )
20
+ return result
@@ -1,5 +1,12 @@
1
- from ase import Atoms
2
- from ase.io import read
1
+ try:
2
+ from ase import Atoms
3
+ from ase.io import read
4
+ except ImportError:
5
+ raise ImportError(
6
+ "The 'ase' package is required for JSON operations with Atoms objects. "
7
+ "To install the optional dependency, use atomict[utils]"
8
+ )
9
+
3
10
  import logging
4
11
  import os
5
12
 
@@ -1,10 +1,18 @@
1
- from atomict.io.fhiaims import read_aims_output
2
- from ase import Atoms
3
- from ase.io import read
4
- from ase.io.formats import UnknownFileTypeError
5
1
  import os
6
2
  import logging
7
3
 
4
+ try:
5
+ from ase import Atoms
6
+ from ase.io import read
7
+ from ase.io.formats import UnknownFileTypeError
8
+ except ImportError:
9
+ raise ImportError(
10
+ "The 'ase' package is required for JSON operations with Atoms objects. "
11
+ "To install the optional dependency, use atomict[utils]"
12
+ )
13
+
14
+ from atomict.io.fhiaims import read_aims_output
15
+
8
16
 
9
17
  def read_final_geometry(workspace_dir: str, simulation_id: str):
10
18
  """Read the starting structure from the workspace directory
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: atomict
3
- Version: 0.1.4
3
+ Version: 0.2.4
4
4
  Summary: The client application for the https://atomictessellator.com/
5
5
  Author-email: Steven Anderson <steven@atomictessellator.com>, Alain Richardt <alain@atomictessellator.com>
6
6
  License: MIT
@@ -18,12 +18,13 @@ Requires-Python: >=3.10
18
18
  Description-Content-Type: text/markdown
19
19
  License-File: LICENSE
20
20
  Requires-Dist: requests
21
- Requires-Dist: ase>=3.23.0
22
21
  Requires-Dist: tenacity~=9.0
23
- Requires-Dist: spglib==2.5.0
24
22
  Requires-Dist: httpx
25
23
  Requires-Dist: click~=8.0
26
24
  Requires-Dist: rich~=13.0
25
+ Provides-Extra: utils
26
+ Requires-Dist: ase==3.23.0; extra == "utils"
27
+ Requires-Dist: spglib==2.5.0; extra == "utils"
27
28
  Provides-Extra: dev
28
29
  Requires-Dist: pytest~=8.0; extra == "dev"
29
30
  Requires-Dist: black; extra == "dev"
@@ -36,6 +37,9 @@ Requires-Dist: flake8; extra == "dev"
36
37
  ## Installation
37
38
  ```
38
39
  pip install atomict
40
+
41
+ # install utils package with scientific extensions (ase, spglib)
42
+ pip install atomict[utils]
39
43
  ```
40
44
 
41
45
  ## Installation for devs
@@ -68,6 +68,7 @@ atomict/simulation/counterfactual.py
68
68
  atomict/simulation/ea.py
69
69
  atomict/simulation/fhi_aims.py
70
70
  atomict/simulation/kpoint.py
71
+ atomict/simulation/mattergen.py
71
72
  atomict/simulation/mlrelax.py
72
73
  atomict/simulation/phonon.py
73
74
  atomict/simulation/qe.py
@@ -1,7 +1,5 @@
1
1
  requests
2
- ase>=3.23.0
3
2
  tenacity~=9.0
4
- spglib==2.5.0
5
3
  httpx
6
4
  click~=8.0
7
5
  rich~=13.0
@@ -12,3 +10,7 @@ black
12
10
  isort
13
11
  mypy
14
12
  flake8
13
+
14
+ [utils]
15
+ ase==3.23.0
16
+ spglib==2.5.0
@@ -41,6 +41,8 @@ version = {attr = "atomict.__version__.__version__"}
41
41
  dependencies = {file = ["requirements.txt"]}
42
42
 
43
43
  [project.optional-dependencies]
44
+ utils = ["ase==3.23.0", "spglib==2.5.0"]
45
+
44
46
  dev = [
45
47
  "pytest~=8.0",
46
48
  "black",
@@ -0,0 +1,8 @@
1
+ # infra
2
+ requests
3
+ tenacity~=9.0
4
+
5
+ # cli
6
+ httpx
7
+ click~=8.0
8
+ rich~=13.0
@@ -1 +0,0 @@
1
- __version__ = "0.1.4"
@@ -1,10 +0,0 @@
1
- # infra
2
- requests # no longer being developed
3
- ase>=3.23.0 # needed for ase.io.aims functions
4
- tenacity~=9.0
5
- spglib==2.5.0
6
-
7
- # cli
8
- httpx
9
- click~=8.0
10
- rich~=13.0
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes