Skip to content

Commit 2b592c0

Browse files
authored
Remove most exports (#152)
1 parent 5284728 commit 2b592c0

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

42 files changed

+502
-371
lines changed

Project.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
name = "ITensorNetworks"
22
uuid = "2919e153-833c-4bdc-8836-1ea460a35fc7"
33
authors = ["Matthew Fishman <[email protected]> and contributors"]
4-
version = "0.4.1"
4+
version = "0.5"
55

66
[deps]
77
AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"

README.md

Lines changed: 14 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ and 3 edge(s):
5252
3 => 4
5353

5454
with vertex data:
55-
4-element Dictionaries.Dictionary{Int64, Any}
55+
4-element Dictionary{Int64, Any}
5656
1 │ ((dim=2|id=739|"1,2"),)
5757
2 │ ((dim=2|id=739|"1,2"), (dim=2|id=920|"2,3"))
5858
3 │ ((dim=2|id=920|"2,3"), (dim=2|id=761|"3,4"))
@@ -104,7 +104,7 @@ and 4 edge(s):
104104
(1, 2) => (2, 2)
105105

106106
with vertex data:
107-
4-element Dictionaries.Dictionary{Tuple{Int64, Int64}, Any}
107+
4-element Dictionary{Tuple{Int64, Int64}, Any}
108108
(1, 1) │ ((dim=2|id=712|"1×1,2×1"), (dim=2|id=598|"1×1,1×2"))
109109
(2, 1) │ ((dim=2|id=712|"1×1,2×1"), (dim=2|id=457|"2×1,2×2"))
110110
(1, 2) │ ((dim=2|id=598|"1×1,1×2"), (dim=2|id=683|"1×2,2×2"))
@@ -134,7 +134,7 @@ and 1 edge(s):
134134
(1, 1) => (1, 2)
135135

136136
with vertex data:
137-
2-element Dictionaries.Dictionary{Tuple{Int64, Int64}, Any}
137+
2-element Dictionary{Tuple{Int64, Int64}, Any}
138138
(1, 1) │ ((dim=2|id=712|"1×1,2×1"), (dim=2|id=598|"1×1,1×2"))
139139
(1, 2) │ ((dim=2|id=598|"1×1,1×2"), (dim=2|id=683|"1×2,2×2"))
140140

@@ -148,7 +148,7 @@ and 1 edge(s):
148148
(2, 1) => (2, 2)
149149

150150
with vertex data:
151-
2-element Dictionaries.Dictionary{Tuple{Int64, Int64}, Any}
151+
2-element Dictionary{Tuple{Int64, Int64}, Any}
152152
(2, 1) │ ((dim=2|id=712|"1×1,2×1"), (dim=2|id=457|"2×1,2×2"))
153153
(2, 2) │ ((dim=2|id=457|"2×1,2×2"), (dim=2|id=683|"1×2,2×2"))
154154
```
@@ -164,7 +164,7 @@ julia> using ITensorNetworks: ⊗, contract, contraction_sequence
164164
julia> using ITensorUnicodePlots: @visualize
165165

166166
julia> s = siteinds("S=1/2", named_grid(3))
167-
ITensorNetworks.IndsNetwork{Int64, ITensors.Index} with 3 vertices:
167+
IndsNetwork{Int64, Index} with 3 vertices:
168168
3-element Vector{Int64}:
169169
1
170170
2
@@ -175,13 +175,13 @@ and 2 edge(s):
175175
2 => 3
176176

177177
with vertex data:
178-
3-element Dictionaries.Dictionary{Int64, Vector{ITensors.Index}}
179-
1ITensors.Index[(dim=2|id=830|"S=1/2,Site,n=1")]
180-
2ITensors.Index[(dim=2|id=369|"S=1/2,Site,n=2")]
181-
3ITensors.Index[(dim=2|id=558|"S=1/2,Site,n=3")]
178+
3-element Dictionary{Int64, Vector{Index}}
179+
1 │ Index[(dim=2|id=830|"S=1/2,Site,n=1")]
180+
2 │ Index[(dim=2|id=369|"S=1/2,Site,n=2")]
181+
3 │ Index[(dim=2|id=558|"S=1/2,Site,n=3")]
182182

183183
and edge data:
184-
0-element Dictionaries.Dictionary{NamedGraphs.NamedEdge{Int64}, Vector{ITensors.Index}}
184+
0-element Dictionary{NamedEdge{Int64}, Vector{Index}}
185185

186186
julia> tn1 = ITensorNetwork(s; link_space=2)
187187
ITensorNetwork{Int64} with 3 vertices:
@@ -195,7 +195,7 @@ and 2 edge(s):
195195
2 => 3
196196

197197
with vertex data:
198-
3-element Dictionaries.Dictionary{Int64, Any}
198+
3-element Dictionary{Int64, Any}
199199
1 │ ((dim=2|id=830|"S=1/2,Site,n=1"), (dim=2|id=186|"1,2"))
200200
2 │ ((dim=2|id=369|"S=1/2,Site,n=2"), (dim=2|id=186|"1,2"), (dim=2|id=430|"2,3…
201201
3 │ ((dim=2|id=558|"S=1/2,Site,n=3"), (dim=2|id=430|"2,3"))
@@ -212,7 +212,7 @@ and 2 edge(s):
212212
2 => 3
213213
214214
with vertex data:
215-
3-element Dictionaries.Dictionary{Int64, Any}
215+
3-element Dictionary{Int64, Any}
216216
1 │ ((dim=2|id=830|"S=1/2,Site,n=1"), (dim=2|id=994|"1,2"))
217217
2 │ ((dim=2|id=369|"S=1/2,Site,n=2"), (dim=2|id=994|"1,2"), (dim=2|id=978|"2,3
218218
3 │ ((dim=2|id=558|"S=1/2,Site,n=3"), (dim=2|id=978|"2,3"))
@@ -293,8 +293,8 @@ julia> @visualize Z;
293293

294294
julia> contraction_sequence(Z)
295295
2-element Vector{Vector}:
296-
NamedGraphs.Key{Tuple{Int64, Int64}}[Key((1, 1)), Key((1, 2))]
297-
Any[Key((2, 1)), Any[Key((2, 2)), NamedGraphs.Key{Tuple{Int64, Int64}}[Key((3, 1)), Key((3, 2))]]]
296+
Key{Tuple{Int64, Int64}}[Key((1, 1)), Key((1, 2))]
297+
Any[Key((2, 1)), Any[Key((2, 2)), Key{Tuple{Int64, Int64}}[Key((3, 1)), Key((3, 2))]]]
298298

299299
julia>= contract(Z, (1, 1) => (2, 1));
300300

examples/Project.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
[deps]
2+
AbstractTrees = "1520ce14-60c1-5f80-bbc7-55ef81b5835c"
3+
DataGraphs = "b5a273c3-7e6c-41f6-98bd-8d7f1525a36a"
24
Graphs = "86223c79-3864-5bf0-83f7-82e725a168b6"
35
ITensorNetworks = "2919e153-833c-4bdc-8836-1ea460a35fc7"
46
ITensorUnicodePlots = "73163f41-4a9e-479f-8353-73bf94dbd758"

examples/boundary.jl

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
1+
using Graphs: vertices
12
using NamedGraphs
23
using ITensors
3-
using ITensorNetworks
4+
using ITensorNetworks: ITensorNetwork
45
using ITensorUnicodePlots
56
using Metis
67

examples/contraction_sequence/contraction_sequence.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
using NamedGraphs
22
using ITensors
3-
using ITensorNetworks
3+
using ITensorNetworks: randomITensorNetwork
44
using Random
55

66
Random.seed!(1234)

examples/dynamics/2d_ising_imag_tebd.jl

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,11 @@
1-
using ITensors
2-
using ITensorNetworks
1+
using Graphs: vertices
2+
using ITensors: ITensors, inner
3+
using ITensors.ITensorMPS: MPO, MPS
4+
using ITensorNetworks: cartesian_to_linear, dmrg, expect, group_terms, ising, siteinds, tebd
35
using ITensorUnicodePlots
4-
using UnicodePlots
5-
using Random
6+
using NamedGraphs: named_grid, rename_vertices
7+
using UnicodePlots: heatmap
8+
using Random: Random
69

710
Random.seed!(1234)
811

examples/dynamics/Project.toml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
[deps]
2+
Graphs = "86223c79-3864-5bf0-83f7-82e725a168b6"
3+
ITensorNetworks = "2919e153-833c-4bdc-8836-1ea460a35fc7"
4+
ITensorUnicodePlots = "73163f41-4a9e-479f-8353-73bf94dbd758"
5+
NamedGraphs = "678767b0-92e7-4007-89e4-4527a8725b19"
6+
UnicodePlots = "b8865327-cd53-5732-bb35-84acbb429228"

examples/examples.jl

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
1-
using ITensors
2-
using ITensorNetworks
3-
using ITensorUnicodePlots
4-
using NamedGraphs
1+
using ITensorNetworks: IndsNetwork, itensors
2+
using ITensorUnicodePlots: @visualize
3+
using NamedGraphs: named_grid
54

65
χ, d = 5, 2
76
system_dims = (4, 4)

examples/mincut.jl

Lines changed: 20 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,23 @@
1-
using NamedGraphs
2-
using ITensors
3-
using ITensorNetworks
4-
using ITensorUnicodePlots
1+
using Graphs:
2+
adjacency_matrix,
3+
bfs_tree,
4+
center,
5+
diameter,
6+
eccentricity,
7+
neighborhood_dists,
8+
nv,
9+
periphery,
10+
radius
11+
using NamedGraphs:
12+
dijkstra_mst,
13+
dijkstra_parents,
14+
dijkstra_tree,
15+
mincut_partitions,
16+
named_grid,
17+
symrcm_permute
18+
using ITensors: dag
19+
using ITensorNetworks: ITensorNetwork, , flatten_networks, siteinds
20+
using ITensorUnicodePlots: @visualize
521

622
g = named_grid(5)
723
s = siteinds("S=1/2", g)

examples/mps.jl

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,10 @@
1-
using AbstractTrees
2-
using ITensors
3-
using ITensorNetworks
1+
using AbstractTrees: print_tree
2+
using DataGraphs: edge_data, vertex_data
3+
using ITensors: contract, dag, sim
4+
using ITensorNetworks: IndsNetwork, ITensorNetwork, contraction_sequence, siteinds
45
using ITensorUnicodePlots
5-
using Random
6-
using NamedGraphs
6+
using Random: Random, randn!
7+
using NamedGraphs: named_path_graph, subgraph
78

89
Random.seed!(1234)
910

0 commit comments

Comments
 (0)