Skip to content
Snippets Groups Projects
Commit cd4695c6 authored by hachmeis@hu-berlin.de's avatar hachmeis@hu-berlin.de
Browse files

+mehr Erklärungen und Struktur

parent d13670f5
No related branches found
No related tags found
No related merge requests found
%% Cell type:markdown id:little-production tags:
# Data Mining
<br/>
<br/>
Dieses Notebook finden Sie hier: https://scm.cms.hu-berlin.de/ibi/python/-/blob/master/programmierspass/Data_Mining.ipynb
<br/>
![CC-BY-NC](https://scm.cms.hu-berlin.de/ibi/python/-/raw/master/img/cc-by-nc.png)
Dieses Notebook ist als freies Werk unter der Lizenz [Creative Commons Attribution-NonCommercial 3.0 Unported](http://creativecommons.org/licenses/by-nc/3.0/) verfügbar. Sie dürfen die Inhalte kopieren, verteilen und verändern, solange Sie die Urheber nennen und sie nicht für kommerzielle Zwecke nutzen.
%% Cell type:markdown id:rising-farming tags:
## Was ist es und worum geht es?
**Data Mining** wird wie folgt definiert:
- **Definition 1 (Synonym zu *Knowledge Discovery in Databases (KDD)*)**: Prozess der (semi-) automatischen Extraktion von Wissen aus Datenbanken, das statistisch gültig, bisher unbekannt und potentiell nützlich ist. [1]
- **Definition 2 (Teil des KDD)**:
- Mustergewinnung/Modellierung
- Interpretation
- Anwendung von Algorithmen, die unter gewissen Ressourcenbeschränkungen Muster/Modelle bei gegebener Faktenmenge erzeugen
**Anwendungsfälle**
- Spamfilterung
- Objekterkennung auf Bildern
- Prüfung der Kreditwürdigkeit von potentiellen Kunden
- Personalisierte Empfehlungen (zum Beispiel auf YouTube und Spotify)
%% Cell type:markdown id:60ef8533 tags:
## Ziel für heute
- kurze Einführung in das Thema
- Anwendungsbeispiele zeigen
- Teaser für die Master-Lehrveranstaltungen *Knowledge Discovery in Databases (KDD)* und *Web Science*
- Inspiration :)
%% Cell type:markdown id:e0ffe431 tags:
**Prozess-Model [1]**
## Prozess-Model des Data Mining [1]
![Screenshot%20from%202023-01-26%2011-31-48.png](attachment:Screenshot%20from%202023-01-26%2011-31-48.png)
**Referenzen**
[1]: (Fayyad, Piatetsky-Shapiro und Smyth 1996) https://ojs.aaai.org//index.php/aimagazine/article/view/1230
%% Cell type:markdown id:88429751 tags:
### Data Mining Tasks
- **Clustering**
- **Klassifikation**
- Regression
- Assoziationsregeln
- ...
%% Cell type:markdown id:collected-genius tags:
%% Cell type:markdown id:2f2a0afc tags:
## Clustering
## Python Bibliotheken die wir heute benutzen:
- [Pandas](https://pandas.pydata.org/) für die **Vorverarbeitung**
- [Seaborn](https://seaborn.pydata.org/) und [Matplotlib](https://matplotlib.org/) zur **Visualisierung**
- [Scikit Learn](https://scikit-learn.org/stable/) zur **Implementierung von Algorithmen** und deren **Evaluation**
%% Cell type:code id:broadband-bathroom tags:
```
import pandas as pd
import seaborn as sns
import matplotlib.pyplot as plt
```
%% Cell type:markdown id:91ec21a4 tags:
## Wie entscheide ich mich für ein Modell?
Abgeleitet vom Ziel der Data Mining Anwendung, wird ein Modell auf Basis des jeweiligen Tasks (Klassifikation, Clustering, Regression, Assoziationsregeln, ...) geählt. Es gibt eine Vielzahl von Modellen. Eine erste Heuristik zur Entscheidung für angemessene Modelle zum experimentieren bietet [SciKit Learn's Machine Learning Map](https://scikit-learn.org/stable/tutorial/machine_learning_map/index.html). Allerdings, hat auch die Bibliothek von SciKit Learn seine Grenzen. Assoziationsregeln sind hier nicht implementiert und auch komplexere Ansätze die auf Neuronalen Netzen basieren, werden üblicherweise mit anderen Bibliotheken implementiert wie bspw. [PyTorch](https://pytorch.org/), [Tensorflow](https://www.tensorflow.org/) oder [Keras](https://keras.io/). Ein paar Beispiele die typischerweise verwendet werden in den jeweiligen Tasks:
**Clustering**
- K-Means
- DBSCAN
**Klassifikation**
- Naive Bayes Klassifikator
- Decision Trees
- Random Forests
- Support Vector Machines
- Neural Networks (bspw. Convolutional Neural Networks, Transformers)
**Regression**
- SGD Regressor
- RidgeRegression
**Assoziationsregeln**
- Apriori Algorithm
- Eclat
%% Cell type:markdown id:collected-genius tags:
# Clustering
Welche Ähnlichkeitsstrukturen liegen in den Daten vor?
Beispiele:
- Welche Gruppen von Kunden sind in der Datenbank?
- Welche Genre sind in der Musiklandschaft vorhanden?
### Exploration
%% Cell type:code id:dd3d70cf tags:
```
```
%% Cell type:markdown id:ef3494f8 tags:
### Vorverarbeitung
%% Cell type:code id:f9ea0aa0 tags:
```
```
%% Cell type:markdown id:f1e44a49 tags:
### Training
%% Cell type:code id:ac572fb0 tags:
```
```
%% Cell type:markdown id:c356bdd5 tags:
### Evaluation
%% Cell type:code id:c3a27e9a tags:
```
```
%% Cell type:markdown id:fixed-corporation tags:
## Classification
## Klassifikation
Beispiele:
- Objekt-Klassifizierung
- Kreditwürdigkeitsprüfung
%% Cell type:markdown id:26e3add5 tags:
### Exploration
%% Cell type:code id:64300d50 tags:
```
```
%% Cell type:markdown id:77e9385e tags:
### Vorverarbeitung
%% Cell type:markdown id:5ae30ad7 tags:
%% Cell type:markdown id:1d742edb tags:
### Training
%% Cell type:code id:fb05ea79 tags:
```
```
%% Cell type:markdown id:32d8ec7a tags:
### Evaluation
%% Cell type:code id:a7c4a702 tags:
```
```
%% Cell type:markdown id:1216f42c tags:
## Klassifikation auf Textdaten
%% Cell type:markdown id:6644498a tags:
### Exploration
%% Cell type:code id:bf0bbab7 tags:
```
```
%% Cell type:markdown id:1b58a4cb tags:
### Vorverarbeitung
%% Cell type:code id:e46bc6d3 tags:
```
```
%% Cell type:markdown id:67a56b07 tags:
### Training
%% Cell type:code id:63ea7162 tags:
```
```
%% Cell type:markdown id:730b3c58 tags:
### Evaluation
%% Cell type:code id:dense-italy tags:
%% Cell type:code id:a9f736fb tags:
```
```
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment