PyQrackIsing 6.2.1__tar.gz → 6.2.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 (29) hide show
  1. {pyqrackising-6.2.1/pyqrackising.egg-info → pyqrackising-6.2.2}/PKG-INFO +1 -1
  2. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyproject.toml +1 -1
  3. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/tsp.py +5 -2
  4. {pyqrackising-6.2.1 → pyqrackising-6.2.2/pyqrackising.egg-info}/PKG-INFO +1 -1
  5. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/setup.py +1 -1
  6. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/CMakeLists.txt +0 -0
  7. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/LICENSE.md +0 -0
  8. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/MANIFEST.in +0 -0
  9. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/README.md +0 -0
  10. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/__init__.py +0 -0
  11. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/_pyqrack_ising.cpp +0 -0
  12. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/convert_tensor_network_to_tsp.py +0 -0
  13. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/generate_tfim_samples.py +0 -0
  14. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/kernels.cl +0 -0
  15. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/maxcut_tfim.py +0 -0
  16. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/maxcut_tfim_sparse.py +0 -0
  17. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/maxcut_tfim_streaming.py +0 -0
  18. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/maxcut_tfim_util.py +0 -0
  19. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/spin_glass_solver.py +0 -0
  20. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/spin_glass_solver_sparse.py +0 -0
  21. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/spin_glass_solver_streaming.py +0 -0
  22. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/spin_glass_solver_util.py +0 -0
  23. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/tfim_magnetization.py +0 -0
  24. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising/tfim_square_magnetization.py +0 -0
  25. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising.egg-info/SOURCES.txt +0 -0
  26. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising.egg-info/dependency_links.txt +0 -0
  27. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising.egg-info/not-zip-safe +0 -0
  28. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/pyqrackising.egg-info/top_level.txt +0 -0
  29. {pyqrackising-6.2.1 → pyqrackising-6.2.2}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyqrackising
3
- Version: 6.2.1
3
+ Version: 6.2.2
4
4
  Summary: Fast MAXCUT, TSP, and sampling heuristics from near-ideal transverse field Ising model (TFIM)
5
5
  Home-page: https://github.com/vm6502q/PyQrackIsing
6
6
  Author: Dan Strano
@@ -12,7 +12,7 @@ build-backend = "setuptools.build_meta"
12
12
 
13
13
  [project]
14
14
  name = "pyqrackising"
15
- version = "6.2.1"
15
+ version = "6.2.2"
16
16
  requires-python = ">=3.8"
17
17
  description = "Fast MAXCUT, TSP, and sampling heuristics from near-ideal transverse field Ising model (TFIM)"
18
18
  readme = {file = "README.txt", content-type = "text/markdown"}
@@ -1,4 +1,5 @@
1
1
  from .spin_glass_solver import spin_glass_solver
2
+ from .maxcut_tfim_util import opencl_context
2
3
  import itertools
3
4
  import networkx as nx
4
5
  from numba import njit
@@ -512,13 +513,14 @@ def tsp_symmetric(
512
513
  multi_start=1,
513
514
  is_top_level=True
514
515
  ):
516
+ dtype = opencl_context.dtype
515
517
  nodes = None
516
518
  n_nodes = 0
517
519
  G_m = None
518
520
  if isinstance(G, nx.Graph):
519
521
  nodes = list(G.nodes())
520
522
  n_nodes = len(nodes)
521
- G_m = nx.to_numpy_array(G, weight='weight', nonedge=0.0)
523
+ G_m = nx.to_numpy_array(G, weight='weight', nonedge=0.0, dtype=dtype)
522
524
  else:
523
525
  n_nodes = len(G)
524
526
  nodes = list(range(n_nodes))
@@ -696,13 +698,14 @@ def tsp_asymmetric(
696
698
  multi_start=1,
697
699
  is_top_level=True
698
700
  ):
701
+ dtype = opencl_context.dtype
699
702
  nodes = None
700
703
  n_nodes = 0
701
704
  G_m = None
702
705
  if isinstance(G, nx.Graph):
703
706
  nodes = list(G.nodes())
704
707
  n_nodes = len(nodes)
705
- G_m = nx.to_numpy_array(G, weight='weight', nonedge=0.0)
708
+ G_m = nx.to_numpy_array(G, weight='weight', nonedge=0.0, dtype=dtype)
706
709
  else:
707
710
  n_nodes = len(G)
708
711
  nodes = list(range(n_nodes))
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: pyqrackising
3
- Version: 6.2.1
3
+ Version: 6.2.2
4
4
  Summary: Fast MAXCUT, TSP, and sampling heuristics from near-ideal transverse field Ising model (TFIM)
5
5
  Home-page: https://github.com/vm6502q/PyQrackIsing
6
6
  Author: Dan Strano
@@ -51,7 +51,7 @@ ext_modules = [CMakeExtension('tfim_sampler')]
51
51
 
52
52
  setup(
53
53
  name='pyqrackising',
54
- version='6.2.1',
54
+ version='6.2.2',
55
55
  author='Dan Strano',
56
56
  author_email='stranoj@gmail.com',
57
57
  description='Fast MAXCUT, TSP, and sampling heuristics from near-ideal transverse field Ising model (TFIM)',
File without changes
File without changes
File without changes
File without changes