Ethics of Machine Learning
Wanheng Hu, Ph.D.
Embedded Ethics Fellow, Stanford University
CS229, Winter 2025
What are we talking about when we talk about the “Ethics of Machine Learning”?
In-class interaction: What comes to your mind when you think of “ML ethics”?
2
Unpacking “Ethics of ML”
Ethics
Machine learning
3
Unpacking “Ethics of ML”
Ethics
Machine learning
4
Unpacking “Ethics of ML”
Ethics
Machine learning
5
Learning Goals
6
A Quick Roadmap
7
Why care? Making ethics visible
8
9
Why care? Making ethics visible
10
Welcome to the “real-world”…
11
12
13
14
Sociotechnical systems
15
16
What’s “sociotechnical” about ML in practice?
In-class activity: in groups of 2-3, choose an ML system and discuss its sociotechnical dimensions – what are the humans and resources that made its creation and functioning possible?
17
Rethinking ML models
18
Rethinking ML models
19
The world we live in
A spectrum of ethical issues for ML-ers…
20
(Saltz et al, 2019)
Oversight related challenges
Q1: Which laws and regulations might be applicable to this project?
Q2: How is ethical accountability achieved?
21
Data related challenges (privacy + anonymity)
Q3: How might the legal rights of organizations and individuals be impinged by our use of the data?
22
Data related challenges (privacy + anonymity)
Q4: How might individuals’ privacy and anonymity be impinged via aggregation and linking of the data?
23
Data related challenges (availability + validity)
Q5: How do you know that the data is ethically available for its intended use?
24
Data related challenges (availability + validity)
Q6: How do you know that the data is valid for its intended use?
25
Model related challenges (bias)
Q7: How have we identified and minimized any bias in the data or in the model?
26
Model related challenges (bias)
Q8: How was any potential modeler bias identified and then, if appropriate, mitigated?
27
Model related challenges (trans + accu)
Q9: How transparent does the model need to be and how is that transparency achieved?
28
Model related challenges (trans + accu)
Q10: What are likely misinterpretations of the results and what can be done to prevent those misinterpretations?
29
Imagine you’re developing a medical ML device
30
(Vayena et al, 2018)
The spectrum can be continued…
31
Let’s look at some popular ML applications
32
ML in medical imaging
33
(Esteva et al., 2019)
ML models can be biased
34
(Ricci Lara et al., 2022)
But what does it mean for a model to be fair?
35
Where do biases come from?
36
How do we mitigate biases?
37
38
A few quick take-aways
39
Generative AI
40
Text-image generation AI apps
41
(Bianchi et al., 2023)
42
?
43
?
44
45
Discussion
46
References (recommended readings in bold)
47
Help us evaluate the Embedded Ethics Program!
https://tinyurl.com/embedethics
10-15 minute survey, taking it (or not) won’t impact your grade in the class in any way, and teaching team won’t know who participates or not.
Option to provide your email address to receive a $10 gift card, up to the first 800 participants. Compensation once per quarter (SUNet login required).
Questions? Email embeddedethics@stanford.edu