Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/pradipnp/decisiontree-iris
Machine learning project to classify iris flowers using a decision tree
https://github.com/pradipnp/decisiontree-iris
classification decision-tree iris-dataset machine-learning python scikit-learn
Last synced: 4 days ago
JSON representation
Machine learning project to classify iris flowers using a decision tree
- Host: GitHub
- URL: https://github.com/pradipnp/decisiontree-iris
- Owner: pradipNP
- Created: 2025-01-25T15:56:52.000Z (20 days ago)
- Default Branch: main
- Last Pushed: 2025-02-04T13:15:55.000Z (10 days ago)
- Last Synced: 2025-02-04T14:22:30.516Z (10 days ago)
- Topics: classification, decision-tree, iris-dataset, machine-learning, python, scikit-learn
- Language: Python
- Homepage:
- Size: 39.1 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# DECISION TREE IMPLEMENTATION
*COMPANY* : CODTECH IT SOLUTIONS
*NAME* : PRADEEP KUMAR KOHAR
*INTERN ID* : CODHC29
*DOMAIN* : MACHINE LEARNING
*DURATION* : 4 WEEKS
*MENTOR* : NEELA SANTOSH
The code in your DecisionTree-Iris project is designed to classify Iris flower species (Setosa, Versicolor, Virginica) using a Decision Tree algorithm implemented in Python with the help of scikit-learn. Below is a detailed breakdown of the code and what each section does:
## Objective:
The goal of this project is to classify Iris flower species (Setosa, Versicolor, Virginica) using a Decision Tree model. The project leverages machine learning techniques to analyze the characteristics of Iris flowers and predict their species based on input features.## Dataset:
The Iris dataset is a well-known dataset in machine learning, containing:- Features (Inputs): Sepal length, Sepal width, Petal length, Petal width.
- Target (Output): Three classes of Iris flowers:
- Setosa
- Versicolor
- Virginica## Workflow:
1. Data Preparation:
The dataset is divided into two parts:- Training Data: Used to train the decision tree model.
- Testing Data: Used to evaluate the model's performance.
2. Model Building:
A Decision Tree algorithm is used to create a classification model. Decision Trees operate by splitting data into subsets based on feature thresholds, forming a tree structure to make predictions.3. Model Evaluation:
The performance of the trained model is measured using metrics like accuracy, ensuring its ability to generalize to unseen data.4. Visualization:
The structure of the decision tree is visualized to provide insights into how decisions are made at each node. The rules governing the splits are also displayed for interpretability.## Key Features of the Project:
- Explainability: The Decision Tree model provides clear, interpretable decision-making rules.
- Visualization: A graphical representation of the tree makes it easier to understand how the model classifies data.
- Practical Use: The project demonstrates the application of machine learning in a simple yet meaningful classification problem.
## Significance:
This project illustrates the power of machine learning in solving classification problems. By using the Iris dataset, it highlights how decision trees can be used to make accurate and interpretable predictions. The visualizations make the learning process intuitive and understandable, even for beginners.## Run iris_decision_tree_visualization.py :
- python iris_decision_tree_visualization.py## Output :
![Image](https://github.com/user-attachments/assets/4eb835ea-db3e-43db-84b6-c99dd6f4287b)
## Run decision_tree.py :
- python decision_tree.py## Outputs :
![Image](https://github.com/user-attachments/assets/7fc30ad2-d7b4-4033-82a7-221863b09e9e)
![Image](https://github.com/user-attachments/assets/50ad7978-56da-4591-9590-0b651f351911)
![Image](https://github.com/user-attachments/assets/847f1039-0730-4808-a123-e4820c708617)