invrs-opt 0.10.0__tar.gz → 0.10.2__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 (25) hide show
  1. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/PKG-INFO +4 -4
  2. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/README.md +1 -1
  3. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/pyproject.toml +3 -3
  4. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/__init__.py +1 -1
  5. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/optimizers/lbfgsb.py +7 -2
  6. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt.egg-info/PKG-INFO +4 -4
  7. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt.egg-info/requires.txt +2 -2
  8. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/LICENSE +0 -0
  9. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/setup.cfg +0 -0
  10. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/experimental/__init__.py +0 -0
  11. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/experimental/client.py +0 -0
  12. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/experimental/labels.py +0 -0
  13. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/optimizers/__init__.py +0 -0
  14. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/optimizers/base.py +0 -0
  15. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/optimizers/wrapped_optax.py +0 -0
  16. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/__init__.py +0 -0
  17. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/base.py +0 -0
  18. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/filter_project.py +0 -0
  19. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/gaussian_levelset.py +0 -0
  20. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/pixel.py +0 -0
  21. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/parameterization/transforms.py +0 -0
  22. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt/py.typed +0 -0
  23. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt.egg-info/SOURCES.txt +0 -0
  24. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt.egg-info/dependency_links.txt +0 -0
  25. {invrs_opt-0.10.0 → invrs_opt-0.10.2}/src/invrs_opt.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: invrs_opt
3
- Version: 0.10.0
3
+ Version: 0.10.2
4
4
  Summary: Algorithms for inverse design
5
5
  Author-email: "Martin F. Schubert" <mfschubert@gmail.com>
6
6
  Maintainer-email: "Martin F. Schubert" <mfschubert@gmail.com>
@@ -513,12 +513,12 @@ Keywords: topology,optimization,jax,inverse design
513
513
  Requires-Python: >=3.7
514
514
  Description-Content-Type: text/markdown
515
515
  License-File: LICENSE
516
- Requires-Dist: jax<=0.4.35
516
+ Requires-Dist: jax>=0.4.35
517
517
  Requires-Dist: jaxlib
518
518
  Requires-Dist: numpy
519
519
  Requires-Dist: requests
520
520
  Requires-Dist: optax
521
- Requires-Dist: scipy
521
+ Requires-Dist: scipy<1.15.0
522
522
  Requires-Dist: totypes
523
523
  Requires-Dist: types-requests
524
524
  Provides-Extra: tests
@@ -533,7 +533,7 @@ Requires-Dist: mypy; extra == "dev"
533
533
  Requires-Dist: pre-commit; extra == "dev"
534
534
 
535
535
  # invrs-opt - Optimization algorithms for inverse design
536
- `v0.10.0`
536
+ `v0.10.2`
537
537
 
538
538
  ## Overview
539
539
 
@@ -1,5 +1,5 @@
1
1
  # invrs-opt - Optimization algorithms for inverse design
2
- `v0.10.0`
2
+ `v0.10.2`
3
3
 
4
4
  ## Overview
5
5
 
@@ -1,7 +1,7 @@
1
1
  [project]
2
2
 
3
3
  name = "invrs_opt"
4
- version = "v0.10.0"
4
+ version = "v0.10.2"
5
5
  description = "Algorithms for inverse design"
6
6
  keywords = ["topology", "optimization", "jax", "inverse design"]
7
7
  readme = "README.md"
@@ -16,12 +16,12 @@ maintainers = [
16
16
  ]
17
17
 
18
18
  dependencies = [
19
- "jax <= 0.4.35",
19
+ "jax >= 0.4.35",
20
20
  "jaxlib",
21
21
  "numpy",
22
22
  "requests",
23
23
  "optax",
24
- "scipy",
24
+ "scipy < 1.15.0",
25
25
  "totypes",
26
26
  "types-requests",
27
27
  ]
@@ -3,7 +3,7 @@
3
3
  Copyright (c) 2023 The INVRS-IO authors.
4
4
  """
5
5
 
6
- __version__ = "v0.10.0"
6
+ __version__ = "v0.10.2"
7
7
  __author__ = "Martin F. Schubert <mfschubert@gmail.com>"
8
8
 
9
9
  from invrs_opt import parameterization as parameterization
@@ -317,7 +317,10 @@ def parameterized_lbfgsb(
317
317
  latent_params = _init_latents(params)
318
318
  metadata, latents = param_base.partition_density_metadata(latent_params)
319
319
  latents, jax_lbfgsb_state = jax.pure_callback(
320
- _init_state_pure, _example_state(latents, maxcor), latents
320
+ _init_state_pure,
321
+ _example_state(latents, maxcor),
322
+ latents,
323
+ vmap_method="sequential",
321
324
  )
322
325
  latent_params = param_base.combine_density_metadata(metadata, latents)
323
326
  return (
@@ -346,7 +349,7 @@ def parameterized_lbfgsb(
346
349
  flat_latent_grad: PyTree,
347
350
  value: jnp.ndarray,
348
351
  jax_lbfgsb_state: JaxLbfgsbDict,
349
- ) -> Tuple[PyTree, NumpyLbfgsbDict]:
352
+ ) -> Tuple[NDArray, NumpyLbfgsbDict]:
350
353
  assert onp.size(value) == 1
351
354
  scipy_lbfgsb_state = ScipyLbfgsbState.from_jax(jax_lbfgsb_state)
352
355
  flat_latent_params = scipy_lbfgsb_state.x.copy()
@@ -355,6 +358,7 @@ def parameterized_lbfgsb(
355
358
  value=onp.array(value, dtype=onp.float64),
356
359
  )
357
360
  updated_flat_latent_params = scipy_lbfgsb_state.x
361
+ flat_latent_updates: NDArray
358
362
  flat_latent_updates = updated_flat_latent_params - flat_latent_params
359
363
  return flat_latent_updates, scipy_lbfgsb_state.to_dict()
360
364
 
@@ -403,6 +407,7 @@ def parameterized_lbfgsb(
403
407
  flat_latents_grad,
404
408
  value,
405
409
  jax_lbfgsb_state,
410
+ vmap_method="sequential",
406
411
  )
407
412
  latent_updates = unflatten_fn(flat_latent_updates)
408
413
  latent_params = _apply_updates(
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: invrs_opt
3
- Version: 0.10.0
3
+ Version: 0.10.2
4
4
  Summary: Algorithms for inverse design
5
5
  Author-email: "Martin F. Schubert" <mfschubert@gmail.com>
6
6
  Maintainer-email: "Martin F. Schubert" <mfschubert@gmail.com>
@@ -513,12 +513,12 @@ Keywords: topology,optimization,jax,inverse design
513
513
  Requires-Python: >=3.7
514
514
  Description-Content-Type: text/markdown
515
515
  License-File: LICENSE
516
- Requires-Dist: jax<=0.4.35
516
+ Requires-Dist: jax>=0.4.35
517
517
  Requires-Dist: jaxlib
518
518
  Requires-Dist: numpy
519
519
  Requires-Dist: requests
520
520
  Requires-Dist: optax
521
- Requires-Dist: scipy
521
+ Requires-Dist: scipy<1.15.0
522
522
  Requires-Dist: totypes
523
523
  Requires-Dist: types-requests
524
524
  Provides-Extra: tests
@@ -533,7 +533,7 @@ Requires-Dist: mypy; extra == "dev"
533
533
  Requires-Dist: pre-commit; extra == "dev"
534
534
 
535
535
  # invrs-opt - Optimization algorithms for inverse design
536
- `v0.10.0`
536
+ `v0.10.2`
537
537
 
538
538
  ## Overview
539
539
 
@@ -1,9 +1,9 @@
1
- jax<=0.4.35
1
+ jax>=0.4.35
2
2
  jaxlib
3
3
  numpy
4
4
  requests
5
5
  optax
6
- scipy
6
+ scipy<1.15.0
7
7
  totypes
8
8
  types-requests
9
9
 
File without changes
File without changes