qupled 0.0.2__tar.gz → 0.0.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.
- qupled-0.0.4/.clang-format +190 -0
- qupled-0.0.4/.github/workflows/build-and-test-linux-mpi.yml +62 -0
- qupled-0.0.4/.github/workflows/build-and-test-linux.yml +63 -0
- qupled-0.0.4/.github/workflows/build-and-test-macos-mpi.yml +64 -0
- qupled-0.0.4/.github/workflows/build-and-test-macos.yml +63 -0
- qupled-0.0.4/.github/workflows/build-and-test.yml +28 -0
- qupled-0.0.4/.github/workflows/formatting.yml +33 -0
- qupled-0.0.4/.github/workflows/release.yml +51 -0
- qupled-0.0.4/.gitignore +10 -0
- qupled-0.0.4/.readthedocs.yaml +17 -0
- qupled-0.0.4/CMakeLists.txt +2 -0
- qupled-0.0.4/LICENSE +674 -0
- qupled-0.0.4/MANIFEST.in +3 -0
- qupled-0.0.4/PKG-INFO +73 -0
- qupled-0.0.4/README.md +44 -0
- qupled-0.0.4/dev/devtool.py +114 -0
- qupled-0.0.4/dev/requirements.txt +15 -0
- qupled-0.0.4/devtool +5 -0
- qupled-0.0.4/docs/_static/css/rdt_theme_python_properties.css +3 -0
- qupled-0.0.4/docs/conf.py +34 -0
- qupled-0.0.4/docs/contribute.rst +34 -0
- qupled-0.0.4/docs/examples.rst +151 -0
- qupled-0.0.4/docs/index.rst +18 -0
- qupled-0.0.4/docs/introduction.rst +87 -0
- qupled-0.0.4/docs/make.bat +35 -0
- qupled-0.0.4/docs/qupled.rst +533 -0
- qupled-0.0.4/docs/requirements.txt +4 -0
- qupled-0.0.4/examples/docs/fixedAdrQVSStls.py +27 -0
- qupled-0.0.4/examples/docs/fixedAdrQstls.py +37 -0
- qupled-0.0.4/examples/docs/fixedAdrQstlsIet.py +27 -0
- qupled-0.0.4/examples/docs/initialGuessQstls.py +19 -0
- qupled-0.0.4/examples/docs/initialGuessQstlsIet.py +20 -0
- qupled-0.0.4/examples/docs/initialGuessStls.py +17 -0
- qupled-0.0.4/examples/docs/solveQVSStls.py +29 -0
- qupled-0.0.4/examples/docs/solveQuantumSchemes.py +30 -0
- qupled-0.0.4/examples/docs/solveRpaAndESA.py +49 -0
- qupled-0.0.4/examples/docs/solveStls.py +28 -0
- qupled-0.0.4/examples/docs/solveStlsIet.py +17 -0
- qupled-0.0.4/examples/docs/solveVSStls.py +30 -0
- qupled-0.0.4/examples/docs/tests/test_examples.py +85 -0
- qupled-0.0.4/examples/readme/animation.py +237 -0
- qupled-0.0.4/examples/readme/qupled_animation_dark.svg +18921 -0
- qupled-0.0.4/examples/readme/qupled_animation_light.svg +20307 -0
- {qupled-0.0.2 → qupled-0.0.4}/pyproject.toml +8 -2
- qupled-0.0.4/setup.py +18 -0
- qupled-0.0.4/src/qupled/__init__.py +1 -0
- qupled-0.0.4/src/qupled/native/include/bin_util.hpp +58 -0
- qupled-0.0.4/src/qupled/native/include/chemical_potential.hpp +25 -0
- qupled-0.0.4/src/qupled/native/include/esa.hpp +30 -0
- qupled-0.0.4/src/qupled/native/include/free_energy.hpp +45 -0
- qupled-0.0.4/src/qupled/native/include/input.hpp +368 -0
- qupled-0.0.4/src/qupled/native/include/internal_energy.hpp +55 -0
- qupled-0.0.4/src/qupled/native/include/logger.hpp +25 -0
- qupled-0.0.4/src/qupled/native/include/mpi_util.hpp +72 -0
- qupled-0.0.4/src/qupled/native/include/num_util.hpp +28 -0
- qupled-0.0.4/src/qupled/native/include/numerics.hpp +422 -0
- qupled-0.0.4/src/qupled/native/include/python_util.hpp +52 -0
- qupled-0.0.4/src/qupled/native/include/python_wrappers.hpp +195 -0
- qupled-0.0.4/src/qupled/native/include/qstls.hpp +333 -0
- qupled-0.0.4/src/qupled/native/include/qvs.hpp +193 -0
- qupled-0.0.4/src/qupled/native/include/rdf.hpp +53 -0
- qupled-0.0.4/src/qupled/native/include/rpa.hpp +302 -0
- qupled-0.0.4/src/qupled/native/include/stls.hpp +200 -0
- qupled-0.0.4/src/qupled/native/include/thermo_util.hpp +31 -0
- qupled-0.0.4/src/qupled/native/include/vector2D.hpp +98 -0
- qupled-0.0.4/src/qupled/native/include/vector3D.hpp +102 -0
- qupled-0.0.4/src/qupled/native/include/vector_util.hpp +47 -0
- qupled-0.0.4/src/qupled/native/include/vsbase.hpp +294 -0
- qupled-0.0.4/src/qupled/native/include/vsstls.hpp +125 -0
- qupled-0.0.4/src/qupled/native/src/CMakeLists.txt +82 -0
- qupled-0.0.4/src/qupled/native/src/chemical_potential.cpp +20 -0
- qupled-0.0.4/src/qupled/native/src/esa.cpp +213 -0
- qupled-0.0.4/src/qupled/native/src/free_energy.cpp +10 -0
- qupled-0.0.4/src/qupled/native/src/input.cpp +368 -0
- qupled-0.0.4/src/qupled/native/src/internal_energy.cpp +12 -0
- qupled-0.0.4/src/qupled/native/src/logger.cpp +11 -0
- qupled-0.0.4/src/qupled/native/src/mpi_util.cpp +174 -0
- qupled-0.0.4/src/qupled/native/src/num_util.cpp +22 -0
- qupled-0.0.4/src/qupled/native/src/numerics.cpp +411 -0
- qupled-0.0.4/src/qupled/native/src/python_modules.cpp +204 -0
- qupled-0.0.4/src/qupled/native/src/python_util.cpp +105 -0
- qupled-0.0.4/src/qupled/native/src/python_wrappers.cpp +281 -0
- qupled-0.0.4/src/qupled/native/src/qstls.cpp +738 -0
- qupled-0.0.4/src/qupled/native/src/qvs.cpp +334 -0
- qupled-0.0.4/src/qupled/native/src/rdf.cpp +24 -0
- qupled-0.0.4/src/qupled/native/src/rpa.cpp +483 -0
- qupled-0.0.4/src/qupled/native/src/stls.cpp +442 -0
- qupled-0.0.4/src/qupled/native/src/thermo_util.cpp +59 -0
- qupled-0.0.4/src/qupled/native/src/vector2D.cpp +111 -0
- qupled-0.0.4/src/qupled/native/src/vector3D.cpp +106 -0
- qupled-0.0.4/src/qupled/native/src/vector_util.cpp +81 -0
- qupled-0.0.4/src/qupled/native/src/vsbase.cpp +548 -0
- qupled-0.0.4/src/qupled/native/src/vsstls.cpp +189 -0
- qupled-0.0.4/src/qupled.egg-info/PKG-INFO +73 -0
- qupled-0.0.4/src/qupled.egg-info/SOURCES.txt +123 -0
- qupled-0.0.4/src/qupled.egg-info/not-zip-safe +1 -0
- qupled-0.0.4/tests/test_esa.py +31 -0
- qupled-0.0.4/tests/test_esa_native.py +43 -0
- qupled-0.0.4/tests/test_hdf.py +172 -0
- qupled-0.0.4/tests/test_plot.py +32 -0
- qupled-0.0.4/tests/test_qstls.py +78 -0
- qupled-0.0.4/tests/test_qstls_iet.py +124 -0
- qupled-0.0.4/tests/test_qstls_input.py +125 -0
- qupled-0.0.4/tests/test_qstls_native.py +89 -0
- qupled-0.0.4/tests/test_qvs.py +139 -0
- qupled-0.0.4/tests/test_qvs_input.py +177 -0
- qupled-0.0.4/tests/test_qvs_native.py +63 -0
- qupled-0.0.4/tests/test_rpa.py +107 -0
- qupled-0.0.4/tests/test_rpa_input.py +188 -0
- qupled-0.0.4/tests/test_rpa_native.py +42 -0
- qupled-0.0.4/tests/test_stls.py +74 -0
- qupled-0.0.4/tests/test_stls_iet.py +66 -0
- qupled-0.0.4/tests/test_stls_input.py +153 -0
- qupled-0.0.4/tests/test_stls_native.py +90 -0
- qupled-0.0.4/tests/test_vsstls.py +80 -0
- qupled-0.0.4/tests/test_vsstls_input.py +163 -0
- qupled-0.0.4/tests/test_vsstls_native.py +51 -0
- qupled-0.0.4/tox.ini +20 -0
- qupled-0.0.2/MANIFEST.in +0 -2
- qupled-0.0.2/PKG-INFO +0 -27
- qupled-0.0.2/qupled/Darwin/qupled.so +0 -0
- qupled-0.0.2/qupled/Linux/qupled.so +0 -0
- qupled-0.0.2/qupled/__init__.py +0 -9
- qupled-0.0.2/qupled.egg-info/PKG-INFO +0 -27
- qupled-0.0.2/qupled.egg-info/SOURCES.txt +0 -13
- {qupled-0.0.2 → qupled-0.0.4}/setup.cfg +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled/classic.py +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled/quantum.py +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled/util.py +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled.egg-info/dependency_links.txt +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled.egg-info/requires.txt +0 -0
- {qupled-0.0.2 → qupled-0.0.4/src}/qupled.egg-info/top_level.txt +0 -0
@@ -0,0 +1,190 @@
|
|
1
|
+
---
|
2
|
+
Language: Cpp
|
3
|
+
# BasedOnStyle: LLVM
|
4
|
+
AccessModifierOffset: -2
|
5
|
+
AlignAfterOpenBracket: Align
|
6
|
+
AlignArrayOfStructures: None
|
7
|
+
AlignConsecutiveMacros: None
|
8
|
+
AlignConsecutiveAssignments: None
|
9
|
+
AlignConsecutiveBitFields: None
|
10
|
+
AlignConsecutiveDeclarations: None
|
11
|
+
AlignEscapedNewlines: Right
|
12
|
+
AlignOperands: Align
|
13
|
+
AlignTrailingComments: true
|
14
|
+
AllowAllArgumentsOnNextLine: true
|
15
|
+
AllowAllParametersOfDeclarationOnNextLine: true
|
16
|
+
AllowShortEnumsOnASingleLine: true
|
17
|
+
AllowShortBlocksOnASingleLine: Always
|
18
|
+
AllowShortCaseLabelsOnASingleLine: true
|
19
|
+
AllowShortFunctionsOnASingleLine: All
|
20
|
+
AllowShortLambdasOnASingleLine: All
|
21
|
+
AllowShortIfStatementsOnASingleLine: WithoutElse
|
22
|
+
AllowShortLoopsOnASingleLine: false
|
23
|
+
AlwaysBreakAfterDefinitionReturnType: None
|
24
|
+
AlwaysBreakAfterReturnType: None
|
25
|
+
AlwaysBreakBeforeMultilineStrings: false
|
26
|
+
AlwaysBreakTemplateDeclarations: Yes
|
27
|
+
AttributeMacros:
|
28
|
+
- __capability
|
29
|
+
BinPackArguments: false
|
30
|
+
BinPackParameters: false
|
31
|
+
BraceWrapping:
|
32
|
+
AfterCaseLabel: false
|
33
|
+
AfterClass: false
|
34
|
+
AfterControlStatement: Never
|
35
|
+
AfterEnum: false
|
36
|
+
AfterFunction: false
|
37
|
+
AfterNamespace: false
|
38
|
+
AfterObjCDeclaration: false
|
39
|
+
AfterStruct: false
|
40
|
+
AfterUnion: false
|
41
|
+
AfterExternBlock: false
|
42
|
+
BeforeCatch: false
|
43
|
+
BeforeElse: false
|
44
|
+
BeforeLambdaBody: false
|
45
|
+
BeforeWhile: false
|
46
|
+
IndentBraces: false
|
47
|
+
SplitEmptyFunction: true
|
48
|
+
SplitEmptyRecord: true
|
49
|
+
SplitEmptyNamespace: true
|
50
|
+
BreakBeforeBinaryOperators: None
|
51
|
+
BreakBeforeConceptDeclarations: true
|
52
|
+
BreakBeforeBraces: Attach
|
53
|
+
BreakBeforeInheritanceComma: false
|
54
|
+
BreakInheritanceList: BeforeColon
|
55
|
+
BreakBeforeTernaryOperators: true
|
56
|
+
BreakConstructorInitializersBeforeComma: false
|
57
|
+
BreakConstructorInitializers: BeforeColon
|
58
|
+
BreakAfterJavaFieldAnnotations: false
|
59
|
+
BreakStringLiterals: true
|
60
|
+
ColumnLimit: 80
|
61
|
+
CommentPragmas: '^ IWYU pragma:'
|
62
|
+
QualifierAlignment: Leave
|
63
|
+
CompactNamespaces: false
|
64
|
+
ConstructorInitializerIndentWidth: 4
|
65
|
+
ContinuationIndentWidth: 4
|
66
|
+
Cpp11BracedListStyle: true
|
67
|
+
DeriveLineEnding: true
|
68
|
+
DerivePointerAlignment: false
|
69
|
+
DisableFormat: false
|
70
|
+
EmptyLineAfterAccessModifier: Always
|
71
|
+
EmptyLineBeforeAccessModifier: Always
|
72
|
+
ExperimentalAutoDetectBinPacking: false
|
73
|
+
PackConstructorInitializers: Never
|
74
|
+
BasedOnStyle: ''
|
75
|
+
ConstructorInitializerAllOnOneLineOrOnePerLine: false
|
76
|
+
AllowAllConstructorInitializersOnNextLine: true
|
77
|
+
FixNamespaceComments: true
|
78
|
+
ForEachMacros:
|
79
|
+
- foreach
|
80
|
+
- Q_FOREACH
|
81
|
+
- BOOST_FOREACH
|
82
|
+
IfMacros:
|
83
|
+
- KJ_IF_MAYBE
|
84
|
+
IncludeBlocks: Preserve
|
85
|
+
IncludeCategories:
|
86
|
+
- Regex: '^"(llvm|llvm-c|clang|clang-c)/'
|
87
|
+
Priority: 2
|
88
|
+
SortPriority: 0
|
89
|
+
CaseSensitive: false
|
90
|
+
- Regex: '^(<|"(gtest|gmock|isl|json)/)'
|
91
|
+
Priority: 3
|
92
|
+
SortPriority: 0
|
93
|
+
CaseSensitive: false
|
94
|
+
- Regex: '.*'
|
95
|
+
Priority: 1
|
96
|
+
SortPriority: 0
|
97
|
+
CaseSensitive: false
|
98
|
+
IncludeIsMainRegex: '(Test)?$'
|
99
|
+
IncludeIsMainSourceRegex: ''
|
100
|
+
IndentAccessModifiers: false
|
101
|
+
IndentCaseLabels: false
|
102
|
+
IndentCaseBlocks: false
|
103
|
+
IndentGotoLabels: true
|
104
|
+
IndentPPDirectives: None
|
105
|
+
IndentExternBlock: AfterExternBlock
|
106
|
+
IndentRequires: false
|
107
|
+
IndentWidth: 2
|
108
|
+
IndentWrappedFunctionNames: false
|
109
|
+
InsertTrailingCommas: None
|
110
|
+
JavaScriptQuotes: Leave
|
111
|
+
JavaScriptWrapImports: true
|
112
|
+
KeepEmptyLinesAtTheStartOfBlocks: true
|
113
|
+
LambdaBodyIndentation: Signature
|
114
|
+
MacroBlockBegin: ''
|
115
|
+
MacroBlockEnd: ''
|
116
|
+
MaxEmptyLinesToKeep: 1
|
117
|
+
NamespaceIndentation: All
|
118
|
+
ObjCBinPackProtocolList: Auto
|
119
|
+
ObjCBlockIndentWidth: 2
|
120
|
+
ObjCBreakBeforeNestedBlockParam: true
|
121
|
+
ObjCSpaceAfterProperty: false
|
122
|
+
ObjCSpaceBeforeProtocolList: true
|
123
|
+
PenaltyBreakAssignment: 2
|
124
|
+
PenaltyBreakBeforeFirstCallParameter: 19
|
125
|
+
PenaltyBreakComment: 300
|
126
|
+
PenaltyBreakFirstLessLess: 120
|
127
|
+
PenaltyBreakOpenParenthesis: 0
|
128
|
+
PenaltyBreakString: 1000
|
129
|
+
PenaltyBreakTemplateDeclaration: 10
|
130
|
+
PenaltyExcessCharacter: 1000000
|
131
|
+
PenaltyReturnTypeOnItsOwnLine: 60
|
132
|
+
PenaltyIndentedWhitespace: 0
|
133
|
+
PointerAlignment: Right
|
134
|
+
PPIndentWidth: -1
|
135
|
+
ReferenceAlignment: Pointer
|
136
|
+
ReflowComments: true
|
137
|
+
RemoveBracesLLVM: false
|
138
|
+
SeparateDefinitionBlocks: Leave
|
139
|
+
ShortNamespaceLines: 1
|
140
|
+
SortIncludes: CaseSensitive
|
141
|
+
SortJavaStaticImport: Before
|
142
|
+
SortUsingDeclarations: true
|
143
|
+
SpaceAfterCStyleCast: false
|
144
|
+
SpaceAfterLogicalNot: false
|
145
|
+
SpaceAfterTemplateKeyword: true
|
146
|
+
SpaceBeforeAssignmentOperators: true
|
147
|
+
SpaceBeforeCaseColon: false
|
148
|
+
SpaceBeforeCpp11BracedList: false
|
149
|
+
SpaceBeforeCtorInitializerColon: true
|
150
|
+
SpaceBeforeInheritanceColon: true
|
151
|
+
SpaceBeforeParens: ControlStatements
|
152
|
+
SpaceBeforeParensOptions:
|
153
|
+
AfterControlStatements: true
|
154
|
+
AfterForeachMacros: true
|
155
|
+
AfterFunctionDefinitionName: false
|
156
|
+
AfterFunctionDeclarationName: false
|
157
|
+
AfterIfMacros: true
|
158
|
+
AfterOverloadedOperator: false
|
159
|
+
BeforeNonEmptyParentheses: false
|
160
|
+
SpaceAroundPointerQualifiers: Default
|
161
|
+
SpaceBeforeRangeBasedForLoopColon: true
|
162
|
+
SpaceInEmptyBlock: false
|
163
|
+
SpaceInEmptyParentheses: false
|
164
|
+
SpacesBeforeTrailingComments: 1
|
165
|
+
SpacesInAngles: Never
|
166
|
+
SpacesInConditionalStatement: false
|
167
|
+
SpacesInContainerLiterals: true
|
168
|
+
SpacesInCStyleCastParentheses: false
|
169
|
+
SpacesInLineCommentPrefix:
|
170
|
+
Minimum: 1
|
171
|
+
Maximum: -1
|
172
|
+
SpacesInParentheses: false
|
173
|
+
SpacesInSquareBrackets: false
|
174
|
+
SpaceBeforeSquareBrackets: false
|
175
|
+
BitFieldColonSpacing: Both
|
176
|
+
Standard: Latest
|
177
|
+
StatementAttributeLikeMacros:
|
178
|
+
- Q_EMIT
|
179
|
+
StatementMacros:
|
180
|
+
- Q_UNUSED
|
181
|
+
- QT_REQUIRE_VERSION
|
182
|
+
TabWidth: 8
|
183
|
+
UseCRLF: false
|
184
|
+
UseTab: Never
|
185
|
+
WhitespaceSensitiveMacros:
|
186
|
+
- STRINGIZE
|
187
|
+
- PP_STRINGIZE
|
188
|
+
- BOOST_PP_STRINGIZE
|
189
|
+
- NS_SWIFT_NAME
|
190
|
+
- CF_SWIFT_NAME
|
@@ -0,0 +1,62 @@
|
|
1
|
+
name: Build & Test (Linux-MPI)
|
2
|
+
|
3
|
+
on:
|
4
|
+
workflow_call:
|
5
|
+
inputs:
|
6
|
+
upload-artifact:
|
7
|
+
required: true
|
8
|
+
type: string
|
9
|
+
build-version:
|
10
|
+
required: false
|
11
|
+
type: string
|
12
|
+
default: ""
|
13
|
+
|
14
|
+
env:
|
15
|
+
PYTHON_VENV_ROOT: ${{ github.workspace }}/python-venv
|
16
|
+
|
17
|
+
jobs:
|
18
|
+
|
19
|
+
build_and_test:
|
20
|
+
|
21
|
+
runs-on: ubuntu-latest
|
22
|
+
|
23
|
+
steps:
|
24
|
+
- name: Checkout repository
|
25
|
+
uses: actions/checkout@v2
|
26
|
+
|
27
|
+
- name: Set up Python
|
28
|
+
uses: actions/setup-python@v4
|
29
|
+
with:
|
30
|
+
python-version: "3.10"
|
31
|
+
|
32
|
+
- name: Install dependencies
|
33
|
+
run: |
|
34
|
+
sudo apt-get update
|
35
|
+
sudo apt-get install -y cmake libboost-all-dev libopenmpi-dev libgsl-dev libomp-dev libfmt-dev python3-dev
|
36
|
+
python3 -m venv ${PYTHON_VENV_ROOT}
|
37
|
+
|
38
|
+
- name: Set build version
|
39
|
+
if: ${{ inputs.build-version != '' }}
|
40
|
+
run: |
|
41
|
+
BUILD_VERSION=${{ inputs.build-version }}
|
42
|
+
sed -i "s/^version = \".*\"/version = \"${BUILD_VERSION}\"/" pyproject.toml
|
43
|
+
|
44
|
+
- name: Build
|
45
|
+
run: |
|
46
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
47
|
+
pip3 install --upgrade pip
|
48
|
+
pip3 install build setuptools
|
49
|
+
./devtool build
|
50
|
+
|
51
|
+
- name: Tests
|
52
|
+
run: |
|
53
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
54
|
+
pip3 install tox
|
55
|
+
./devtool test
|
56
|
+
|
57
|
+
- name: Upload artifact
|
58
|
+
if: ${{ success() && inputs.upload-artifact == 'true' }}
|
59
|
+
uses: actions/upload-artifact@v4
|
60
|
+
with:
|
61
|
+
name: qupled-linux-mpi
|
62
|
+
path: dist
|
@@ -0,0 +1,63 @@
|
|
1
|
+
name: Build & Test (Linux)
|
2
|
+
|
3
|
+
on:
|
4
|
+
workflow_call:
|
5
|
+
inputs:
|
6
|
+
upload-artifact:
|
7
|
+
required: true
|
8
|
+
type: string
|
9
|
+
build-version:
|
10
|
+
required: false
|
11
|
+
type: string
|
12
|
+
default: ""
|
13
|
+
|
14
|
+
env:
|
15
|
+
PYTHON_VENV_ROOT: ${{ github.workspace }}/python-venv
|
16
|
+
|
17
|
+
jobs:
|
18
|
+
|
19
|
+
build_and_test:
|
20
|
+
|
21
|
+
runs-on: ubuntu-latest
|
22
|
+
|
23
|
+
steps:
|
24
|
+
- name: Checkout repository
|
25
|
+
uses: actions/checkout@v2
|
26
|
+
|
27
|
+
- name: Set up Python
|
28
|
+
uses: actions/setup-python@v4
|
29
|
+
with:
|
30
|
+
python-version: "3.10"
|
31
|
+
|
32
|
+
- name: Install dependencies
|
33
|
+
run: |
|
34
|
+
sudo apt-get update
|
35
|
+
sudo apt-get install -y cmake libboost-all-dev libgsl-dev libomp-dev libfmt-dev python3-dev
|
36
|
+
python3 -m venv ${PYTHON_VENV_ROOT}
|
37
|
+
pip3 install --upgrade pip
|
38
|
+
|
39
|
+
- name: Set build version
|
40
|
+
if: ${{ inputs.build-version != '' }}
|
41
|
+
run: |
|
42
|
+
BUILD_VERSION=${{ inputs.build-version }}
|
43
|
+
sed -i "s/^version = \".*\"/version = \"${BUILD_VERSION}\"/" pyproject.toml
|
44
|
+
|
45
|
+
- name: Build
|
46
|
+
run: |
|
47
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
48
|
+
pip3 install --upgrade pip
|
49
|
+
pip3 install build setuptools
|
50
|
+
./devtool build --nompi
|
51
|
+
|
52
|
+
- name: Tests
|
53
|
+
run: |
|
54
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
55
|
+
pip3 install tox
|
56
|
+
./devtool test
|
57
|
+
|
58
|
+
- name: Upload artifact
|
59
|
+
if: ${{ success() && inputs.upload-artifact == 'true' }}
|
60
|
+
uses: actions/upload-artifact@v4
|
61
|
+
with:
|
62
|
+
name: qupled-linux
|
63
|
+
path: dist
|
@@ -0,0 +1,64 @@
|
|
1
|
+
name: Build & Test (macOS-MPI)
|
2
|
+
|
3
|
+
on:
|
4
|
+
workflow_call:
|
5
|
+
inputs:
|
6
|
+
upload-artifact:
|
7
|
+
required: true
|
8
|
+
type: string
|
9
|
+
build-version:
|
10
|
+
required: false
|
11
|
+
type: string
|
12
|
+
default: ""
|
13
|
+
|
14
|
+
env:
|
15
|
+
PYTHON_VENV_ROOT: ${{ github.workspace }}/python-venv
|
16
|
+
|
17
|
+
jobs:
|
18
|
+
|
19
|
+
build_and_test:
|
20
|
+
|
21
|
+
runs-on: macos-latest
|
22
|
+
|
23
|
+
steps:
|
24
|
+
- name: Checkout repository
|
25
|
+
uses: actions/checkout@v2
|
26
|
+
|
27
|
+
- name: Set up Python
|
28
|
+
uses: actions/setup-python@v4
|
29
|
+
with:
|
30
|
+
python-version: "3.12"
|
31
|
+
|
32
|
+
- name: Install dependencies
|
33
|
+
run: |
|
34
|
+
brew update
|
35
|
+
brew install cmake gsl libomp openmpi fmt boost-python3
|
36
|
+
python3 -m venv ${PYTHON_VENV_ROOT}
|
37
|
+
pip3 install --upgrade pip
|
38
|
+
|
39
|
+
- name: Set build version
|
40
|
+
if: ${{ inputs.build-version != '' }}
|
41
|
+
run: |
|
42
|
+
BUILD_VERSION=${{ inputs.build-version }}
|
43
|
+
sed -i "" "s/^version = \".*\"/version = \"${BUILD_VERSION}\"/" pyproject.toml
|
44
|
+
|
45
|
+
- name: Build
|
46
|
+
run: |
|
47
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
48
|
+
export OpenMP_ROOT=$(brew --prefix)/opt/libomp
|
49
|
+
pip3 install --upgrade pip
|
50
|
+
pip3 install build setuptools
|
51
|
+
./devtool build
|
52
|
+
|
53
|
+
- name: Tests
|
54
|
+
run: |
|
55
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
56
|
+
pip3 install tox
|
57
|
+
./devtool test
|
58
|
+
|
59
|
+
- name: Upload artifact
|
60
|
+
if: ${{ success() && inputs.upload-artifact == 'true' }}
|
61
|
+
uses: actions/upload-artifact@v4
|
62
|
+
with:
|
63
|
+
name: qupled-macos-mpi
|
64
|
+
path: dist
|
@@ -0,0 +1,63 @@
|
|
1
|
+
name: Build & Test (macOS)
|
2
|
+
|
3
|
+
on:
|
4
|
+
workflow_call:
|
5
|
+
inputs:
|
6
|
+
upload-artifact:
|
7
|
+
required: true
|
8
|
+
type: string
|
9
|
+
build-version:
|
10
|
+
required: false
|
11
|
+
type: string
|
12
|
+
default: ""
|
13
|
+
|
14
|
+
env:
|
15
|
+
PYTHON_VENV_ROOT: ${{ github.workspace }}/python-venv
|
16
|
+
|
17
|
+
jobs:
|
18
|
+
|
19
|
+
build_and_test:
|
20
|
+
|
21
|
+
runs-on: macos-latest
|
22
|
+
|
23
|
+
steps:
|
24
|
+
- name: Checkout repository
|
25
|
+
uses: actions/checkout@v2
|
26
|
+
|
27
|
+
- name: Set up Python
|
28
|
+
uses: actions/setup-python@v4
|
29
|
+
with:
|
30
|
+
python-version: "3.12"
|
31
|
+
|
32
|
+
- name: Install dependencies
|
33
|
+
run: |
|
34
|
+
brew update
|
35
|
+
brew install cmake gsl libomp fmt boost-python3
|
36
|
+
python3 -m venv ${PYTHON_VENV_ROOT}
|
37
|
+
|
38
|
+
- name: Set build version
|
39
|
+
if: ${{ inputs.build-version != '' }}
|
40
|
+
run: |
|
41
|
+
BUILD_VERSION=${{ inputs.build-version }}
|
42
|
+
sed -i "" "s/^version = \".*\"/version = \"${BUILD_VERSION}\"/" pyproject.toml
|
43
|
+
|
44
|
+
- name: Build
|
45
|
+
run: |
|
46
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
47
|
+
pip3 install --upgrade pip
|
48
|
+
pip3 install build setuptools
|
49
|
+
export OpenMP_ROOT=$(brew --prefix)/opt/libomp
|
50
|
+
./devtool build --nompi
|
51
|
+
|
52
|
+
- name: Tests
|
53
|
+
run: |
|
54
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
55
|
+
pip3 install tox
|
56
|
+
./devtool test
|
57
|
+
|
58
|
+
- name: Upload artifact
|
59
|
+
if: ${{ success() && inputs.upload-artifact == 'true' }}
|
60
|
+
uses: actions/upload-artifact@v4
|
61
|
+
with:
|
62
|
+
name: qupled-macos
|
63
|
+
path: dist
|
@@ -0,0 +1,28 @@
|
|
1
|
+
name: Build & Test
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
pull_request:
|
6
|
+
branches:
|
7
|
+
- master
|
8
|
+
|
9
|
+
jobs:
|
10
|
+
linux:
|
11
|
+
uses: ./.github/workflows/build-and-test-linux.yml
|
12
|
+
with:
|
13
|
+
upload-artifact: false
|
14
|
+
|
15
|
+
macos:
|
16
|
+
uses: ./.github/workflows/build-and-test-macos.yml
|
17
|
+
with:
|
18
|
+
upload-artifact: false
|
19
|
+
|
20
|
+
linux-MPI:
|
21
|
+
uses: ./.github/workflows/build-and-test-linux-mpi.yml
|
22
|
+
with:
|
23
|
+
upload-artifact: false
|
24
|
+
|
25
|
+
macos-MPI:
|
26
|
+
uses: ./.github/workflows/build-and-test-macos-mpi.yml
|
27
|
+
with:
|
28
|
+
upload-artifact: false
|
@@ -0,0 +1,33 @@
|
|
1
|
+
name: Code Formatting
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
pull_request:
|
6
|
+
|
7
|
+
jobs:
|
8
|
+
format:
|
9
|
+
runs-on: ubuntu-latest
|
10
|
+
|
11
|
+
steps:
|
12
|
+
- name: Checkout repository
|
13
|
+
uses: actions/checkout@v2
|
14
|
+
|
15
|
+
- name: Set up Python
|
16
|
+
uses: actions/setup-python@v2
|
17
|
+
with:
|
18
|
+
python-version: '3.12'
|
19
|
+
|
20
|
+
- name: Install dependencies
|
21
|
+
run: |
|
22
|
+
pip3 install --upgrade pip
|
23
|
+
pip3 install black # Install Black for Python formatting
|
24
|
+
sudo apt update
|
25
|
+
sudo apt-get install clang-format
|
26
|
+
|
27
|
+
- name: Check Python formatting
|
28
|
+
run: black --check .
|
29
|
+
|
30
|
+
- name: Check C++ formatting
|
31
|
+
run: |
|
32
|
+
find . -name "*.cpp" | xargs clang-format --style=file --dry-run -Werror
|
33
|
+
find . -name "*.hpp" | xargs clang-format --style=file --dry-run -Werror
|
@@ -0,0 +1,51 @@
|
|
1
|
+
name: Release
|
2
|
+
|
3
|
+
on:
|
4
|
+
push:
|
5
|
+
tags:
|
6
|
+
- 'v*'
|
7
|
+
|
8
|
+
env:
|
9
|
+
PYTHON_VENV_ROOT: ${{ github.workspace }}/python-venv
|
10
|
+
|
11
|
+
jobs:
|
12
|
+
|
13
|
+
build-and-test-linux:
|
14
|
+
uses: ./.github/workflows/build-and-test-linux-mpi.yml
|
15
|
+
with:
|
16
|
+
upload-artifact: true
|
17
|
+
build-version: ${GITHUB_REF#refs/tags/v}
|
18
|
+
|
19
|
+
build-and-test-macos:
|
20
|
+
uses: ./.github/workflows/build-and-test-macos-mpi.yml
|
21
|
+
with:
|
22
|
+
upload-artifact: true
|
23
|
+
build-version: ${GITHUB_REF#refs/tags/v}
|
24
|
+
|
25
|
+
publish:
|
26
|
+
|
27
|
+
runs-on: ubuntu-latest
|
28
|
+
needs: [build-and-test-linux, build-and-test-macos]
|
29
|
+
|
30
|
+
steps:
|
31
|
+
|
32
|
+
- name: Download linux package
|
33
|
+
uses: actions/download-artifact@v4
|
34
|
+
with:
|
35
|
+
name: qupled-linux-mpi
|
36
|
+
path: qupled-linux-mpi
|
37
|
+
|
38
|
+
- name: Set up Python environment
|
39
|
+
run: |
|
40
|
+
python3 -m venv ${PYTHON_VENV_ROOT}
|
41
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
42
|
+
pip3 install --upgrade pip
|
43
|
+
pip3 install twine
|
44
|
+
|
45
|
+
- name: Publish to PyPI
|
46
|
+
env:
|
47
|
+
TWINE_USERNAME: ${{ secrets.PYPI_USERNAME }}
|
48
|
+
TWINE_PASSWORD: ${{ secrets.PYPI_PASSWORD }}
|
49
|
+
run: |
|
50
|
+
source ${PYTHON_VENV_ROOT}/bin/activate
|
51
|
+
twine upload --non-interactive qupled-linux-mpi/*.tar.gz
|
qupled-0.0.4/.gitignore
ADDED
@@ -0,0 +1,17 @@
|
|
1
|
+
# Required
|
2
|
+
version: 2
|
3
|
+
|
4
|
+
# Set the version of Python and other tools you might need
|
5
|
+
build:
|
6
|
+
os: ubuntu-22.04
|
7
|
+
tools:
|
8
|
+
python: "3.11"
|
9
|
+
|
10
|
+
# Build documentation in the docs/ directory with Sphinx
|
11
|
+
sphinx:
|
12
|
+
configuration: docs/conf.py
|
13
|
+
|
14
|
+
# Optionally declare the Python requirements required to build your docs
|
15
|
+
python:
|
16
|
+
install:
|
17
|
+
- requirements: docs/requirements.txt
|