rumale 0.22.5 → 0.23.2

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 (43) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +21 -0
  3. data/LICENSE.txt +1 -1
  4. data/README.md +34 -2
  5. data/ext/rumale/extconf.rb +1 -1
  6. data/ext/rumale/{tree.c → rumaleext.c} +51 -85
  7. data/ext/rumale/{tree.h → rumaleext.h} +5 -5
  8. data/lib/rumale/clustering/hdbscan.rb +28 -8
  9. data/lib/rumale/clustering/single_linkage.rb +23 -5
  10. data/lib/rumale/decomposition/fast_ica.rb +1 -1
  11. data/lib/rumale/ensemble/gradient_boosting_classifier.rb +2 -2
  12. data/lib/rumale/ensemble/gradient_boosting_regressor.rb +1 -1
  13. data/lib/rumale/ensemble/random_forest_classifier.rb +1 -1
  14. data/lib/rumale/ensemble/random_forest_regressor.rb +1 -1
  15. data/lib/rumale/evaluation_measure/roc_auc.rb +1 -2
  16. data/lib/rumale/kernel_approximation/nystroem.rb +1 -1
  17. data/lib/rumale/kernel_machine/kernel_svc.rb +1 -1
  18. data/lib/rumale/linear_model/linear_regression.rb +5 -3
  19. data/lib/rumale/linear_model/ridge.rb +3 -3
  20. data/lib/rumale/model_selection/grid_search_cv.rb +3 -3
  21. data/lib/rumale/naive_bayes/bernoulli_nb.rb +1 -1
  22. data/lib/rumale/naive_bayes/gaussian_nb.rb +1 -1
  23. data/lib/rumale/naive_bayes/multinomial_nb.rb +1 -1
  24. data/lib/rumale/nearest_neighbors/vp_tree.rb +2 -0
  25. data/lib/rumale/tree/base_decision_tree.rb +15 -10
  26. data/lib/rumale/tree/decision_tree_classifier.rb +14 -11
  27. data/lib/rumale/tree/decision_tree_regressor.rb +0 -1
  28. data/lib/rumale/tree/gradient_tree_regressor.rb +15 -11
  29. data/lib/rumale/version.rb +1 -1
  30. data/lib/rumale.rb +132 -133
  31. metadata +6 -17
  32. data/.coveralls.yml +0 -1
  33. data/.github/workflows/build.yml +0 -26
  34. data/.github/workflows/coverage.yml +0 -28
  35. data/.gitignore +0 -23
  36. data/.rspec +0 -3
  37. data/.rubocop.yml +0 -93
  38. data/.travis.yml +0 -17
  39. data/Gemfile +0 -17
  40. data/Rakefile +0 -14
  41. data/ext/rumale/rumale.c +0 -10
  42. data/ext/rumale/rumale.h +0 -8
  43. data/rumale.gemspec +0 -49
@@ -1,26 +0,0 @@
1
- name: build
2
-
3
- on: [push, pull_request]
4
-
5
- jobs:
6
- build:
7
- runs-on: ubuntu-latest
8
- strategy:
9
- fail-fast: false
10
- matrix:
11
- ruby: [ '2.5', '2.6', '2.7', '3.0' ]
12
- steps:
13
- - uses: actions/checkout@v2
14
- - name: Install BLAS and LAPACK
15
- run: sudo apt-get install -y libopenblas-dev liblapacke-dev
16
- - name: Set up Ruby ${{ matrix.ruby }}
17
- uses: actions/setup-ruby@v1
18
- with:
19
- ruby-version: ${{ matrix.ruby }}
20
- - name: Build and test with Rake
21
- env:
22
- LD_LIBRARY_PATH: '/usr/lib/x86_64-linux-gnu/'
23
- run: |
24
- gem install --no-document bundler
25
- bundle install --jobs 4 --retry 3
26
- bundle exec rake
@@ -1,28 +0,0 @@
1
- name: coverage
2
-
3
- on:
4
- push:
5
- branches: [ main ]
6
- pull_request:
7
- branches: [ main ]
8
-
9
- jobs:
10
- coverage:
11
- runs-on: ubuntu-20.04
12
- steps:
13
- - uses: actions/checkout@v2
14
- - name: Install BLAS and LAPACK
15
- run: sudo apt-get install -y libopenblas-dev liblapacke-dev
16
- - name: Set up Ruby 2.7
17
- uses: actions/setup-ruby@v1
18
- with:
19
- ruby-version: '2.7'
20
- - name: Build and test with Rake
21
- run: |
22
- gem install bundler
23
- bundle install
24
- bundle exec rake
25
- - name: Coveralls GitHub Action
26
- uses: coverallsapp/github-action@v1.1.2
27
- with:
28
- github-token: ${{ secrets.GITHUB_TOKEN }}
data/.gitignore DELETED
@@ -1,23 +0,0 @@
1
- /.bundle/
2
- /.yardoc
3
- /Gemfile.lock
4
- /_yardoc/
5
- /coverage/
6
- /doc/
7
- /pkg/
8
- /spec/reports/
9
- /tmp/
10
-
11
- # rspec failure tracking
12
- .rspec_status
13
-
14
- *.swp
15
- *.bundle
16
- tags
17
- .DS_Store
18
- .ruby-version
19
- iterate.dat
20
- /spec/dump_dbl.t
21
- /spec/dump_int.t
22
- /spec/dump_mult_dbl.t
23
- /spec/dump_zb.t
data/.rspec DELETED
@@ -1,3 +0,0 @@
1
- --format documentation
2
- --color
3
- --require spec_helper
data/.rubocop.yml DELETED
@@ -1,93 +0,0 @@
1
- require:
2
- - rubocop-performance
3
- - rubocop-rake
4
- - rubocop-rspec
5
-
6
- AllCops:
7
- NewCops: enable
8
- TargetRubyVersion: 2.5
9
- DisplayCopNames: true
10
- DisplayStyleGuide: true
11
- Exclude:
12
- - 'ext/rumale/extconf.rb'
13
- - 'rumale.gemspec'
14
- - 'Rakefile'
15
- - 'Gemfile'
16
-
17
- Style/Documentation:
18
- Enabled: false
19
-
20
- Layout/LineLength:
21
- Max: 145
22
- IgnoredPatterns: ['(\A|\s)#']
23
-
24
- Lint/ConstantDefinitionInBlock:
25
- Enabled: false
26
-
27
- Lint/MissingSuper:
28
- Enabled: false
29
-
30
- Metrics/ModuleLength:
31
- Max: 200
32
-
33
- Metrics/ClassLength:
34
- Max: 200
35
-
36
- Metrics/MethodLength:
37
- Max: 40
38
-
39
- Metrics/AbcSize:
40
- Max: 60
41
-
42
- Metrics/CyclomaticComplexity:
43
- Max: 16
44
-
45
- Metrics/PerceivedComplexity:
46
- Max: 16
47
-
48
- Metrics/BlockLength:
49
- Max: 40
50
- Exclude:
51
- - 'spec/**/*'
52
-
53
- Metrics/ParameterLists:
54
- Max: 15
55
-
56
- Security/MarshalLoad:
57
- Enabled: false
58
-
59
- Naming/MethodParameterName:
60
- Enabled: false
61
-
62
- Naming/ConstantName:
63
- Enabled: false
64
-
65
- Style/FormatStringToken:
66
- Enabled: false
67
-
68
- Style/NumericLiterals:
69
- Enabled: false
70
-
71
- Style/StringConcatenation:
72
- Enabled: false
73
-
74
- RSpec/MultipleExpectations:
75
- Enabled: false
76
-
77
- RSpec/MultipleMemoizedHelpers:
78
- Max: 25
79
-
80
- RSpec/NestedGroups:
81
- Max: 4
82
-
83
- RSpec/ExampleLength:
84
- Max: 40
85
-
86
- RSpec/InstanceVariable:
87
- Enabled: false
88
-
89
- RSpec/LeakyConstantDeclaration:
90
- Enabled: false
91
-
92
- Performance/Sum:
93
- Enabled: false
data/.travis.yml DELETED
@@ -1,17 +0,0 @@
1
- ---
2
- language: ruby
3
- cache: bundler
4
- rvm:
5
- - '2.4'
6
- - '2.5'
7
- - '2.6'
8
- - '2.7'
9
-
10
- addons:
11
- apt:
12
- packages:
13
- - libopenblas-dev
14
- - liblapacke-dev
15
-
16
- before_install:
17
- - gem install bundler -v 2.1.4
data/Gemfile DELETED
@@ -1,17 +0,0 @@
1
- source 'https://rubygems.org'
2
-
3
- # Specify your gem's dependencies in rumale.gemspec
4
- gemspec
5
-
6
- gem 'mmh3', '>= 1.0'
7
- gem 'numo-linalg', '>= 0.1.4'
8
- gem 'parallel', '>= 1.17.0'
9
- gem 'rake', '~> 13.0'
10
- gem 'rake-compiler', '~> 1.0'
11
- gem 'rspec', '~> 3.0'
12
- gem 'rubocop', '~> 1.0'
13
- gem 'rubocop-performance', '~> 1.8'
14
- gem 'rubocop-rake', '~> 0.5'
15
- gem 'rubocop-rspec', '~> 2.0'
16
- gem 'simplecov', '~> 0.21'
17
- gem 'simplecov-lcov', '~> 0.8'
data/Rakefile DELETED
@@ -1,14 +0,0 @@
1
- require 'bundler/gem_tasks'
2
- require 'rspec/core/rake_task'
3
-
4
- RSpec::Core::RakeTask.new(:spec)
5
-
6
- require 'rake/extensiontask'
7
-
8
- task :build => :compile
9
-
10
- Rake::ExtensionTask.new('rumale') do |ext|
11
- ext.lib_dir = 'lib/rumale'
12
- end
13
-
14
- task :default => [:clobber, :compile, :spec]
data/ext/rumale/rumale.c DELETED
@@ -1,10 +0,0 @@
1
- #include "rumale.h"
2
-
3
- VALUE mRumale;
4
-
5
- void Init_rumale(void)
6
- {
7
- mRumale = rb_define_module("Rumale");
8
-
9
- init_tree_module();
10
- }
data/ext/rumale/rumale.h DELETED
@@ -1,8 +0,0 @@
1
- #ifndef RUMALE_H
2
- #define RUMALE_H 1
3
-
4
- #include <ruby.h>
5
-
6
- #include "tree.h"
7
-
8
- #endif /* RUMALE_H */
data/rumale.gemspec DELETED
@@ -1,49 +0,0 @@
1
- lib = File.expand_path('lib', __dir__)
2
- $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
3
- require 'rumale/version'
4
-
5
- Gem::Specification.new do |spec|
6
- spec.name = 'rumale'
7
- spec.version = Rumale::VERSION
8
- spec.authors = ['yoshoku']
9
- spec.email = ['yoshoku@outlook.com']
10
-
11
- spec.summary = <<~MSG
12
- Rumale is a machine learning library in Ruby.
13
- Rumale provides machine learning algorithms with interfaces similar to Scikit-Learn in Python.
14
- MSG
15
- spec.description = <<~MSG
16
- Rumale is a machine learning library in Ruby.
17
- Rumale provides machine learning algorithms with interfaces similar to Scikit-Learn in Python.
18
- Rumale supports Support Vector Machine,
19
- Logistic Regression, Ridge, Lasso,
20
- Multi-layer Perceptron,
21
- Naive Bayes, Decision Tree, Gradient Tree Boosting, Random Forest,
22
- K-Means, Gaussian Mixture Model, DBSCAN, Spectral Clustering,
23
- Mutidimensional Scaling, t-SNE,
24
- Fisher Discriminant Analysis, Neighbourhood Component Analysis,
25
- Principal Component Analysis, Non-negative Matrix Factorization,
26
- and many other algorithms.
27
- MSG
28
- spec.homepage = 'https://github.com/yoshoku/rumale'
29
- spec.license = 'BSD-2-Clause'
30
-
31
- spec.files = `git ls-files -z`.split("\x0").reject do |f|
32
- f.match(%r{^(test|spec|features)/})
33
- end
34
- spec.bindir = 'exe'
35
- spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
36
- spec.require_paths = ['lib']
37
- spec.extensions = ['ext/rumale/extconf.rb']
38
-
39
- spec.metadata = {
40
- 'homepage_uri' => 'https://github.com/yoshoku/rumale',
41
- 'changelog_uri' => 'https://github.com/yoshoku/rumale/blob/main/CHANGELOG.md',
42
- 'source_code_uri' => 'https://github.com/yoshoku/rumale',
43
- 'documentation_uri' => 'https://yoshoku.github.io/rumale/doc/',
44
- 'bug_tracker_uri' => 'https://github.com/yoshoku/rumale/issues'
45
- }
46
-
47
- spec.add_runtime_dependency 'numo-narray', '>= 0.9.1'
48
- spec.add_runtime_dependency 'lbfgsb', '>=0.3.0'
49
- end