networkx 0.1.1 → 0.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/{CODE_OF_CONDUCT.md → .github/CODE_OF_CONDUCT.md} +0 -0
- data/{CONTRIBUTING.md → .github/CONTRIBUTING.md} +20 -10
- data/{ISSUE_TEMPLATE.md → .github/ISSUE_TEMPLATE.md} +1 -1
- data/{PULL_REQUEST_TEMPLATE.md → .github/PULL_REQUEST_TEMPLATE.md} +2 -4
- data/.github/workflows/ci.yml +17 -0
- data/.github/workflows/doc.yml +23 -0
- data/.rspec +0 -1
- data/.rubocop.yml +57 -71
- data/.yardopts +0 -1
- data/README.md +32 -34
- data/Rakefile +2 -3
- data/lib/networkx/auxillary_functions/cliques.rb +9 -12
- data/lib/networkx/auxillary_functions/cycles.rb +17 -7
- data/lib/networkx/auxillary_functions/dag.rb +10 -5
- data/lib/networkx/auxillary_functions/eccentricity.rb +2 -1
- data/lib/networkx/auxillary_functions/mis.rb +2 -2
- data/lib/networkx/auxillary_functions/mst.rb +1 -3
- data/lib/networkx/auxillary_functions/union_find.rb +92 -12
- data/lib/networkx/auxillary_functions/wiener.rb +1 -1
- data/lib/networkx/converters/to_csv.rb +1 -3
- data/lib/networkx/converters/to_json.rb +0 -2
- data/lib/networkx/digraph.rb +55 -49
- data/lib/networkx/flow/capacityscaling.rb +29 -35
- data/lib/networkx/flow/edmondskarp.rb +17 -15
- data/lib/networkx/flow/preflowpush.rb +29 -32
- data/lib/networkx/flow/shortestaugmentingpath.rb +17 -20
- data/lib/networkx/flow/utils.rb +6 -27
- data/lib/networkx/graph.rb +179 -72
- data/lib/networkx/link_analysis/hits.rb +9 -9
- data/lib/networkx/link_analysis/pagerank.rb +29 -31
- data/lib/networkx/multidigraph.rb +90 -81
- data/lib/networkx/multigraph.rb +91 -63
- data/lib/networkx/operators/all.rb +8 -4
- data/lib/networkx/operators/binary.rb +106 -128
- data/lib/networkx/operators/product.rb +61 -64
- data/lib/networkx/operators/unary.rb +1 -1
- data/lib/networkx/others/bridges.rb +30 -0
- data/lib/networkx/others/generators.rb +237 -0
- data/lib/networkx/others/grid_2d_graph.rb +38 -0
- data/lib/networkx/others/info.rb +11 -0
- data/lib/networkx/others/number_connected_components.rb +17 -0
- data/lib/networkx/others/reads.rb +52 -0
- data/lib/networkx/shortest_path/astar.rb +10 -8
- data/lib/networkx/shortest_path/dense.rb +1 -3
- data/lib/networkx/shortest_path/unweighted.rb +13 -16
- data/lib/networkx/shortest_path/weighted.rb +51 -42
- data/lib/networkx/to_matrix.rb +2 -3
- data/lib/networkx/traversals/bfs.rb +54 -2
- data/lib/networkx/traversals/dfs.rb +62 -6
- data/lib/networkx/traversals/edge_dfs.rb +36 -12
- data/lib/networkx/version.rb +1 -1
- data/lib/networkx.rb +7 -1
- data/networkx.gemspec +17 -14
- metadata +74 -84
- data/.rspec_formatter.rb +0 -24
- data/.travis.yml +0 -18
- data/Guardfile +0 -7
- data/RELEASE_POLICY.md +0 -20
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: networkx
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Athitya Kumar
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2022-11-26 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -16,220 +16,204 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - "~>"
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '2.0'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
24
|
- - "~>"
|
25
25
|
- !ruby/object:Gem::Version
|
26
|
-
version: '
|
26
|
+
version: '2.0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rake
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
31
|
- - "~>"
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '13.0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
38
|
- - "~>"
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '13.0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
|
-
name:
|
42
|
+
name: rspec
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- - "
|
45
|
+
- - "~>"
|
46
46
|
- !ruby/object:Gem::Version
|
47
|
-
version: '0'
|
47
|
+
version: '3.0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- - "
|
52
|
+
- - "~>"
|
53
53
|
- !ruby/object:Gem::Version
|
54
|
-
version: '0'
|
54
|
+
version: '3.0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
|
-
name: rspec
|
56
|
+
name: rspec-its
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
59
|
- - "~>"
|
60
60
|
- !ruby/object:Gem::Version
|
61
|
-
version: '
|
61
|
+
version: '1.0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
66
|
- - "~>"
|
67
67
|
- !ruby/object:Gem::Version
|
68
|
-
version: '
|
68
|
+
version: '1.0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
70
|
-
name:
|
70
|
+
name: rubocop
|
71
71
|
requirement: !ruby/object:Gem::Requirement
|
72
72
|
requirements:
|
73
|
-
- - "
|
73
|
+
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: '0'
|
75
|
+
version: '1.0'
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
|
-
- - "
|
80
|
+
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: '0'
|
82
|
+
version: '1.0'
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
|
-
name: rubocop
|
84
|
+
name: rubocop-rake
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- - "
|
87
|
+
- - "~>"
|
88
88
|
- !ruby/object:Gem::Version
|
89
|
-
version: 0.
|
89
|
+
version: '0.6'
|
90
90
|
type: :development
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- - "
|
94
|
+
- - "~>"
|
95
95
|
- !ruby/object:Gem::Version
|
96
|
-
version: 0.
|
96
|
+
version: '0.6'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: rubocop-rspec
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- - "
|
101
|
+
- - "~>"
|
102
102
|
- !ruby/object:Gem::Version
|
103
|
-
version: '0'
|
103
|
+
version: '2.0'
|
104
104
|
type: :development
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- - "
|
108
|
+
- - "~>"
|
109
109
|
- !ruby/object:Gem::Version
|
110
|
-
version: '0'
|
110
|
+
version: '2.0'
|
111
111
|
- !ruby/object:Gem::Dependency
|
112
112
|
name: rubygems-tasks
|
113
113
|
requirement: !ruby/object:Gem::Requirement
|
114
114
|
requirements:
|
115
|
-
- - "
|
115
|
+
- - "~>"
|
116
116
|
- !ruby/object:Gem::Version
|
117
|
-
version: '0'
|
117
|
+
version: '0.2'
|
118
118
|
type: :development
|
119
119
|
prerelease: false
|
120
120
|
version_requirements: !ruby/object:Gem::Requirement
|
121
121
|
requirements:
|
122
|
-
- - "
|
122
|
+
- - "~>"
|
123
123
|
- !ruby/object:Gem::Version
|
124
|
-
version: '0'
|
124
|
+
version: '0.2'
|
125
125
|
- !ruby/object:Gem::Dependency
|
126
126
|
name: saharspec
|
127
127
|
requirement: !ruby/object:Gem::Requirement
|
128
128
|
requirements:
|
129
|
-
- - "
|
129
|
+
- - "~>"
|
130
130
|
- !ruby/object:Gem::Version
|
131
|
-
version: '0'
|
131
|
+
version: '0.0'
|
132
132
|
type: :development
|
133
133
|
prerelease: false
|
134
134
|
version_requirements: !ruby/object:Gem::Requirement
|
135
135
|
requirements:
|
136
|
-
- - "
|
136
|
+
- - "~>"
|
137
137
|
- !ruby/object:Gem::Version
|
138
|
-
version: '0'
|
138
|
+
version: '0.0'
|
139
139
|
- !ruby/object:Gem::Dependency
|
140
140
|
name: simplecov
|
141
141
|
requirement: !ruby/object:Gem::Requirement
|
142
142
|
requirements:
|
143
|
-
- - "
|
143
|
+
- - "~>"
|
144
144
|
- !ruby/object:Gem::Version
|
145
|
-
version: '0'
|
145
|
+
version: '0.21'
|
146
146
|
type: :development
|
147
147
|
prerelease: false
|
148
148
|
version_requirements: !ruby/object:Gem::Requirement
|
149
149
|
requirements:
|
150
|
-
- - "
|
150
|
+
- - "~>"
|
151
151
|
- !ruby/object:Gem::Version
|
152
|
-
version: '0'
|
152
|
+
version: '0.21'
|
153
153
|
- !ruby/object:Gem::Dependency
|
154
154
|
name: yard
|
155
155
|
requirement: !ruby/object:Gem::Requirement
|
156
156
|
requirements:
|
157
|
-
- - "
|
157
|
+
- - "~>"
|
158
158
|
- !ruby/object:Gem::Version
|
159
|
-
version: '0'
|
159
|
+
version: '0.9'
|
160
160
|
type: :development
|
161
161
|
prerelease: false
|
162
162
|
version_requirements: !ruby/object:Gem::Requirement
|
163
163
|
requirements:
|
164
|
-
- - "
|
164
|
+
- - "~>"
|
165
165
|
- !ruby/object:Gem::Version
|
166
|
-
version: '0'
|
166
|
+
version: '0.9'
|
167
167
|
- !ruby/object:Gem::Dependency
|
168
|
-
name:
|
168
|
+
name: matrix
|
169
169
|
requirement: !ruby/object:Gem::Requirement
|
170
170
|
requirements:
|
171
|
-
- - "
|
171
|
+
- - "~>"
|
172
172
|
- !ruby/object:Gem::Version
|
173
|
-
version: '0'
|
173
|
+
version: '0.4'
|
174
174
|
type: :runtime
|
175
175
|
prerelease: false
|
176
176
|
version_requirements: !ruby/object:Gem::Requirement
|
177
177
|
requirements:
|
178
|
-
- - "
|
178
|
+
- - "~>"
|
179
179
|
- !ruby/object:Gem::Version
|
180
|
-
version: '0'
|
180
|
+
version: '0.4'
|
181
181
|
- !ruby/object:Gem::Dependency
|
182
182
|
name: rb_heap
|
183
183
|
requirement: !ruby/object:Gem::Requirement
|
184
184
|
requirements:
|
185
|
-
- - "
|
185
|
+
- - "~>"
|
186
186
|
- !ruby/object:Gem::Version
|
187
|
-
version: '0'
|
187
|
+
version: '1.0'
|
188
188
|
type: :runtime
|
189
189
|
prerelease: false
|
190
190
|
version_requirements: !ruby/object:Gem::Requirement
|
191
191
|
requirements:
|
192
|
-
- - "
|
193
|
-
- !ruby/object:Gem::Version
|
194
|
-
version: '0'
|
195
|
-
- !ruby/object:Gem::Dependency
|
196
|
-
name: guard-rspec
|
197
|
-
requirement: !ruby/object:Gem::Requirement
|
198
|
-
requirements:
|
199
|
-
- - ">="
|
200
|
-
- !ruby/object:Gem::Version
|
201
|
-
version: '0'
|
202
|
-
type: :development
|
203
|
-
prerelease: false
|
204
|
-
version_requirements: !ruby/object:Gem::Requirement
|
205
|
-
requirements:
|
206
|
-
- - ">="
|
192
|
+
- - "~>"
|
207
193
|
- !ruby/object:Gem::Version
|
208
|
-
version: '0'
|
194
|
+
version: '1.0'
|
209
195
|
description: ' A Ruby implemenation of the well-known graph library called "networkx".
|
210
196
|
|
211
|
-
'
|
197
|
+
'
|
212
198
|
email:
|
213
199
|
- athityakumar@gmail.com
|
214
200
|
executables: []
|
215
201
|
extensions: []
|
216
202
|
extra_rdoc_files: []
|
217
203
|
files:
|
204
|
+
- ".github/CODE_OF_CONDUCT.md"
|
205
|
+
- ".github/CONTRIBUTING.md"
|
206
|
+
- ".github/ISSUE_TEMPLATE.md"
|
207
|
+
- ".github/PULL_REQUEST_TEMPLATE.md"
|
208
|
+
- ".github/workflows/ci.yml"
|
209
|
+
- ".github/workflows/doc.yml"
|
218
210
|
- ".gitignore"
|
219
211
|
- ".rspec"
|
220
|
-
- ".rspec_formatter.rb"
|
221
212
|
- ".rubocop.yml"
|
222
|
-
- ".travis.yml"
|
223
213
|
- ".yardopts"
|
224
|
-
- CODE_OF_CONDUCT.md
|
225
|
-
- CONTRIBUTING.md
|
226
214
|
- Gemfile
|
227
|
-
- Guardfile
|
228
|
-
- ISSUE_TEMPLATE.md
|
229
215
|
- LICENSE.md
|
230
|
-
- PULL_REQUEST_TEMPLATE.md
|
231
216
|
- README.md
|
232
|
-
- RELEASE_POLICY.md
|
233
217
|
- Rakefile
|
234
218
|
- lib/networkx.rb
|
235
219
|
- lib/networkx/auxillary_functions/cliques.rb
|
@@ -258,6 +242,12 @@ files:
|
|
258
242
|
- lib/networkx/operators/binary.rb
|
259
243
|
- lib/networkx/operators/product.rb
|
260
244
|
- lib/networkx/operators/unary.rb
|
245
|
+
- lib/networkx/others/bridges.rb
|
246
|
+
- lib/networkx/others/generators.rb
|
247
|
+
- lib/networkx/others/grid_2d_graph.rb
|
248
|
+
- lib/networkx/others/info.rb
|
249
|
+
- lib/networkx/others/number_connected_components.rb
|
250
|
+
- lib/networkx/others/reads.rb
|
261
251
|
- lib/networkx/shortest_path/astar.rb
|
262
252
|
- lib/networkx/shortest_path/dense.rb
|
263
253
|
- lib/networkx/shortest_path/unweighted.rb
|
@@ -268,11 +258,12 @@ files:
|
|
268
258
|
- lib/networkx/traversals/edge_dfs.rb
|
269
259
|
- lib/networkx/version.rb
|
270
260
|
- networkx.gemspec
|
271
|
-
homepage: https://github.com/
|
261
|
+
homepage: https://github.com/SciRuby/networkx.rb
|
272
262
|
licenses:
|
273
263
|
- MIT
|
274
|
-
metadata:
|
275
|
-
|
264
|
+
metadata:
|
265
|
+
rubygems_mfa_required: 'true'
|
266
|
+
post_install_message:
|
276
267
|
rdoc_options: []
|
277
268
|
require_paths:
|
278
269
|
- lib
|
@@ -280,16 +271,15 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
280
271
|
requirements:
|
281
272
|
- - ">="
|
282
273
|
- !ruby/object:Gem::Version
|
283
|
-
version: '
|
274
|
+
version: '2.7'
|
284
275
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
285
276
|
requirements:
|
286
277
|
- - ">="
|
287
278
|
- !ruby/object:Gem::Version
|
288
279
|
version: '0'
|
289
280
|
requirements: []
|
290
|
-
|
291
|
-
|
292
|
-
signing_key:
|
281
|
+
rubygems_version: 3.3.3
|
282
|
+
signing_key:
|
293
283
|
specification_version: 4
|
294
284
|
summary: A Ruby implemenation of the well-known graph library called networkx.
|
295
285
|
test_files: []
|
data/.rspec_formatter.rb
DELETED
@@ -1,24 +0,0 @@
|
|
1
|
-
RSpec::Support.require_rspec_core 'formatters/base_text_formatter'
|
2
|
-
|
3
|
-
class SimpleFormatter < RSpec::Core::Formatters::BaseTextFormatter
|
4
|
-
RSpec::Core::Formatters.register self,
|
5
|
-
:example_passed, :example_pending, :example_failed, :dump_pending, :dump_failures, :dump_summary
|
6
|
-
|
7
|
-
def example_passed(message); end
|
8
|
-
|
9
|
-
def example_pending(message); end
|
10
|
-
|
11
|
-
def example_failed(message); end
|
12
|
-
|
13
|
-
def dump_pending(message); end
|
14
|
-
|
15
|
-
def dump_failures(message); end
|
16
|
-
|
17
|
-
def dump_summary(message)
|
18
|
-
colorizer = ::RSpec::Core::Formatters::ConsoleCodes
|
19
|
-
|
20
|
-
output.puts "\nFinished in #{message.formatted_duration} " \
|
21
|
-
"(files took #{message.formatted_load_time} to load)\n" \
|
22
|
-
"#{message.colorized_totals_line(colorizer)}\n"
|
23
|
-
end
|
24
|
-
end
|
data/.travis.yml
DELETED
@@ -1,18 +0,0 @@
|
|
1
|
-
language:
|
2
|
-
ruby
|
3
|
-
|
4
|
-
rvm:
|
5
|
-
- '2.1'
|
6
|
-
- '2.2'
|
7
|
-
- '2.3.0'
|
8
|
-
- '2.4.0'
|
9
|
-
|
10
|
-
script:
|
11
|
-
- bundle exec rspec
|
12
|
-
- bundle exec rubocop
|
13
|
-
|
14
|
-
install:
|
15
|
-
- gem install bundler
|
16
|
-
- gem install rainbow -v '2.2.1'
|
17
|
-
- sudo apt-get update -qq
|
18
|
-
- bundle install
|
data/Guardfile
DELETED
data/RELEASE_POLICY.md
DELETED
@@ -1,20 +0,0 @@
|
|
1
|
-
# RELEASE POLICY
|
2
|
-
|
3
|
-
Applicable from networkx v0.0.0 onwards
|
4
|
-
|
5
|
-
### Versioning
|
6
|
-
|
7
|
-
NetworkX follows semantic versioning whereby the version number is always in the form MAJOR.MINOR.PATCH
|
8
|
-
|
9
|
-
- Patch bump : Bug fixes
|
10
|
-
- Minor bump : New features (with backwards compatibility)
|
11
|
-
- Major bump : API breaking changes
|
12
|
-
|
13
|
-
For Major and Minor bumps release candidates should be released around 2 weeks prior to the bump and are indicated by MAJOR.MINOR.0.rc.
|
14
|
-
|
15
|
-
For more information see the full semantic versioning specification at http://semver.org/.
|
16
|
-
|
17
|
-
### Release Timing
|
18
|
-
|
19
|
-
Patch releases should be done after every fix of a major bug (as tagged in the github issue tracker).
|
20
|
-
Major releases should be kept to the minimum.
|