Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TERPSICHORE #1046

Draft
wants to merge 68 commits into
base: dd/external
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 34 commits
Commits
Show all changes
68 commits
Select commit Hold shift + click to select a range
b0d4507
added objective file wrapping the TERPSICHORE linear stability code
mfmart Apr 12, 2024
19c90a9
initial work on terpsichore wrapper
Apr 9, 2024
d139eac
added terpsichore objective to __init__. Other small modifications
Apr 15, 2024
ec81ac1
TERPS running successfully when fixing all parameters
Apr 26, 2024
0f84f07
Merge remote-tracking branch 'origin/master' into terps
Apr 26, 2024
c48c240
merge w/ master
Apr 26, 2024
50f0446
modified run_terps() and write_terps_io() to account for new dynamica…
May 2, 2024
71c0d75
Merge remote-tracking branch 'origin/master' into terps
May 2, 2024
6611b24
terps finite differences working with old version of terps (need to c…
May 3, 2024
86120df
Merge remote-tracking branch 'origin/master' into terps
May 3, 2024
ae87214
not currently recognizing 'seff' in subprocess...
May 6, 2024
2f7f9b1
commented block with some initial parallelization debugging
Jun 4, 2024
e9f6848
small modifications for dynamic terps
Jun 4, 2024
54c9f44
modifications for dynamic TERPS and assuming the tpr16* files are no …
Jun 5, 2024
29bfc8c
Changed modelk input parameter default to modelk=1
Jun 7, 2024
aced031
Merge branch 'dd/external' into terps
ddudt Jun 7, 2024
fea999f
clean up TERPSICHORE to work with _ExternalObjective
daniel-dudt Jun 7, 2024
199c657
fix TERPS input order
daniel-dudt Jun 7, 2024
4156f40
adding lssl and lssd
daniel-dudt Jun 7, 2024
9c24b73
debugging dynamic terps
Jun 10, 2024
0dd1781
Merge remote-tracking branch 'origin' into terps
Jun 10, 2024
c85b849
merging w/ Daniel's changes to _terpsichore objective
Jun 10, 2024
8929534
write input additions for dynamic TERPS
Jun 10, 2024
89ade9b
edit srun command
daniel-dudt Jun 10, 2024
a340f95
subprocess.run with single command
daniel-dudt Jun 10, 2024
4e03bca
temporary dir for external fun calls
daniel-dudt Jun 10, 2024
c4bbd79
remove debugging print statements
daniel-dudt Jun 11, 2024
dcdba44
Merge branch 'dd/external' into terps
ddudt Jun 11, 2024
0d76cc5
remove srun
daniel-dudt Jun 11, 2024
35e4859
adding comments
daniel-dudt Jun 11, 2024
55ae538
Merge branch 'dd/external' into terps
ddudt Jun 11, 2024
e9575ae
remove eq_id
daniel-dudt Jun 11, 2024
4e48203
set mode_family < 0 to include all mode families
mfmart Jun 13, 2024
95d26c7
set mode_family < 0 to use all mode families within active mode range
mfmart Jun 14, 2024
bc1f6fd
black formatting
daniel-dudt Jun 17, 2024
222284b
Merge branch 'dd/external' into terps
ddudt Jun 17, 2024
32ece01
streamlined write_wout function
daniel-dudt Jun 17, 2024
4e6471d
Merge branch 'terps' of https://github.com/PlasmaControl/DESC into terps
daniel-dudt Jun 17, 2024
d0b1e5b
Merge branch 'dd/external' into terps
ddudt Jun 17, 2024
e941eab
set default growth rate to al0
daniel-dudt Jul 15, 2024
f0a4f95
Merge branch 'dd/external' into terps
ddudt Jul 22, 2024
1836369
fix vmec save typo
daniel-dudt Jul 22, 2024
06bc103
precompute vmec transforms
daniel-dudt Jul 22, 2024
685cf00
multiprocessing (at least on CPU, maybe GPU?)
daniel-dudt Jul 22, 2024
750017e
Merge branch 'dd/external' into terps
ddudt Jul 23, 2024
557637f
set terpsichore fun to run on cpu
daniel-dudt Jul 23, 2024
6bb920e
update defaults
daniel-dudt Jul 24, 2024
0a98ce2
Merge branch 'dd/external' into terps
ddudt Jul 24, 2024
c49c3e0
execute_on_cpu
daniel-dudt Jul 24, 2024
8db9279
Merge branch 'dd/external' into terps
ddudt Jul 24, 2024
df3fb8a
Merge branch 'dd/external' into terps
ddudt Jul 26, 2024
2efe860
Merge branch 'dd/external' into terps
ddudt Jul 30, 2024
782b232
fix bug in write_terps_input
daniel-dudt Aug 9, 2024
2be9d53
Merge branch 'dd/external' into terps
ddudt Aug 11, 2024
379f71a
Merge branch 'dd/external' into terps
ddudt Aug 22, 2024
82ceb26
Merge branch 'dd/external' into terps
ddudt Aug 23, 2024
f5e1913
Merge branch 'dd/external' into terps
ddudt Aug 25, 2024
deb6867
Merge branch 'dd/external' into terps
ddudt Aug 25, 2024
60ee83c
Merge branch 'dd/external' into terps
ddudt Aug 26, 2024
c9d42e0
update units and print format
daniel-dudt Aug 26, 2024
e17ccf2
Merge branch 'dd/external' into terps
ddudt Aug 27, 2024
90c2655
update notes
daniel-dudt Aug 28, 2024
5400bfc
update with dd/external
daniel-dudt Nov 7, 2024
549105a
add scalar option for dW instead of growth rate
daniel-dudt Nov 7, 2024
e04d360
Merge branch 'dd/external' into terps
ddudt Nov 12, 2024
ced7336
add new args to multiprocessing call
daniel-dudt Nov 12, 2024
5030d74
better default values for delta W
daniel-dudt Nov 14, 2024
ea093e9
comment notes about thresholds
daniel-dudt Nov 19, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions desc/objectives/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@
)
from ._profiles import Pressure, RotationalTransform, Shear, ToroidalCurrent
from ._stability import MagneticWell, MercierStability
from ._terpsichore import TERPSICHORE
from .getters import (
get_equilibrium_objective,
get_fixed_axis_constraints,
Expand Down
3 changes: 3 additions & 0 deletions desc/objectives/_generic.py
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ class _ExternalObjective(_Objective, ABC):
The user supplied function must take an Equilibrium as its only positional argument,
but can take additional keyword arguments.

# TODO: document that driver script has to include ``if __name__ == "__main__":``

# TODO: add Parameters documentation

Parameters
Expand Down Expand Up @@ -146,6 +148,7 @@ def fun_wrapped(params):
if isinstance(self._vectorized, int)
else os.cpu_count()
)
# TODO: re-use same pool
with mp.Pool(processes=min(max_processes, num_eq)) as pool:
results = pool.map(
functools.partial(self._fun, **self._kwargs), eqs
Expand Down
Loading
Loading