Skip to Content
Python数据科学手册
book

Python数据科学手册

by Jake VanderPlas
January 2018
Intermediate to advanced
470 pages
13h 23m
Chinese
Posts & Telecom Press
Content preview from Python数据科学手册
302
|
第
5
章
图 5-12:鸢尾花数据集的可视化
特征矩阵和目标数组的布局如图
5-13
所示。
图 5-13:Scikit-Learn 数据表布局
有了适当的数据形式之后,就可以开始学习
Scikit-Learn
的
评估器
API
了。
5.2.2
 
Scikit-Learn
的评估器
API
Scikit-Learn API
主要遵照以下设计原则,
Scikit-Learn API
文档也对此有所概述。
机器学习
|
303
统一性
所有对象使用共同接口连接一组方法和统一的文档。
内省
所有参数值都是公共属性。
限制对象层级
只有算法可以用
Python
类表示。数据集都用标准数据类型(
NumPy
数组、
Pandas
DataFrame
、
SciPy
稀疏矩阵)表示,参数名称用标准的
Python
字符串。
函数组合
许多机器学习任务都可以用一串基本算法实现,
Scikit-Learn
尽力支持这种可能。
明智的默认值
当模型需要用户设置参数时,
Scikit-Learn
预先定义适当的默认值。
只要你理解了这些设计原则,就会发现
Scikit-Learn
非常容易使用。
Scikit-Learn
中的所有
机器学习算法都是通过评估器
API
实现的,它为各种机器学习应用提供了统一的接口。
1. API
基础知识
Scikit-Learn
评估器
API
的常用步骤如下所示(后面介绍的示例都是按照这些步骤进行的) ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

流畅的Python

流畅的Python

Luciano Ramalho
Python数据分析基础

Python数据分析基础

Clinton W. Brownley
Python数据处理

Python数据处理

Jacqueline Kazil, Katharine Jarmul

Publisher Resources

ISBN: 9787115475893