[devdocsgjs/main: 1373/1867] Update scikit-learn documentation (0.23.2)
- From: Andy Holmes <andyholmes src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [devdocsgjs/main: 1373/1867] Update scikit-learn documentation (0.23.2)
- Date: Fri, 19 Nov 2021 23:47:55 +0000 (UTC)
commit 56c323653642ea2012c9e010b63131a34024babc
Author: Phil Scherer <pnscher evoforge org>
Date: Sun Dec 13 05:21:25 2020 -0500
Update scikit-learn documentation (0.23.2)
assets/javascripts/templates/pages/about_tmpl.coffee | 2 +-
lib/docs/filters/scikit_learn/clean_html.rb | 15 ++++++++-------
lib/docs/scrapers/scikit_learn.rb | 19 +++++++++++--------
3 files changed, 20 insertions(+), 16 deletions(-)
---
diff --git a/assets/javascripts/templates/pages/about_tmpl.coffee
b/assets/javascripts/templates/pages/about_tmpl.coffee
index 5c83e92b..bf65a3db 100644
--- a/assets/javascripts/templates/pages/about_tmpl.coffee
+++ b/assets/javascripts/templates/pages/about_tmpl.coffee
@@ -743,7 +743,7 @@ credits = [
'http://scikit-image.org/docs/dev/license.html'
], [
'scikit-learn',
- '2007-2018 The scikit-learn developers',
+ '2007-2020 The scikit-learn developers',
'BSD',
'https://raw.githubusercontent.com/scikit-learn/scikit-learn/master/COPYING'
], [
diff --git a/lib/docs/filters/scikit_learn/clean_html.rb b/lib/docs/filters/scikit_learn/clean_html.rb
index 200a31a1..ca95d7f4 100644
--- a/lib/docs/filters/scikit_learn/clean_html.rb
+++ b/lib/docs/filters/scikit_learn/clean_html.rb
@@ -3,22 +3,23 @@ module Docs
class CleanHtmlFilter < Filter
def call
if root_page?
- at_css('h1').content = 'scikit-learn'
-
- css('.row-fluid').each do |node|
+ css('.row').each do |node|
html = '<dl>'
- node.css('.span4').each do |n|
- html += "<dt>#{n.first_element_child.inner_html}</dt>"
- html += "<dd>#{n.last_element_child.inner_html}</dd>"
+ node.css('.card-body').each do |n|
+ html += '<dt>'
+ html += "<a href='#{n.at_css('a')['href']}'>#{n.at_css('h4').content}</a>"
+ html += '</dt>'
+ html += "<dd>#{n.css('.card-text').to_html}</dd>"
end
html += '</dl>'
node.replace(html)
end
end
+ css('.sphx-glr-signature').remove
+
doc
end
end
end
end
-
diff --git a/lib/docs/scrapers/scikit_learn.rb b/lib/docs/scrapers/scikit_learn.rb
index 933484f0..f211d7a5 100644
--- a/lib/docs/scrapers/scikit_learn.rb
+++ b/lib/docs/scrapers/scikit_learn.rb
@@ -3,25 +3,28 @@ module Docs
self.name = 'scikit-learn'
self.slug = 'scikit_learn'
self.type = 'sphinx'
- self.release = '0.20.0'
- self.base_url = 'http://scikit-learn.org/stable/'
- self.root_path = 'documentation.html'
+ self.release = '0.23.2'
+ self.base_url = 'https://scikit-learn.org/0.23/'
+ self.root_path = 'index.html'
self.force_gzip = true
self.links = {
- home: 'http://scikit-learn.org/',
+ home: 'https://scikit-learn.org/',
code: 'https://github.com/scikit-learn/scikit-learn'
}
- html_filters.push 'scikit_learn/entries', 'scikit_learn/clean_html', 'sphinx/clean_html'
+ html_filters.push 'scikit_learn/entries', 'scikit_learn/clean_html', 'sphinx/clean_html', 'title'
- options[:container] = ->(filter) { filter.root_page? ? '.container-index' : '.body' }
- options[:skip] = %w(tutorial/statistical_inference/finding_help.html)
+ options[:container] = ->(filter) { filter.root_page? ? 'body > .container' : '.section' }
+ options[:skip] = %w(modules/generated/sklearn.experimental.enable_iterative_imputer.html
+ modules/generated/sklearn.experimental.enable_hist_gradient_boosting.html)
options[:only_patterns] = [/\Amodules/, /\Adatasets/, /\Atutorial/, /\Aauto_examples/]
options[:skip_patterns] = [/\Adatasets\/(?!index)/]
+ options[:title] = false
+ options[:root_title] = 'scikit-learn'
options[:max_image_size] = 256_000
options[:attribution] = <<-HTML
- © 2007–2018 The scikit-learn developers<br>
+ © 2007–2020 The scikit-learn developers<br>
Licensed under the 3-clause BSD License.
HTML
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]