Skip to content

Commit

Permalink
Merge pull request #93 from Aydinhamedi/main
Browse files Browse the repository at this point in the history
merge
  • Loading branch information
Aydinhamedi authored Jan 10, 2024
2 parents e9c99b1 + 2c783bf commit 855117b
Show file tree
Hide file tree
Showing 6 changed files with 102 additions and 40 deletions.
20 changes: 20 additions & 0 deletions .github/workflows/dependency-review.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Dependency Review Action
#
# This Action will scan dependency manifest files that change as part of a Pull Request, surfacing known-vulnerable versions of the packages declared or updated in the PR. Once installed, if the workflow run is marked as required, PRs introducing known-vulnerable packages will be blocked from merging.
#
# Source repository: https://github.com/actions/dependency-review-action
# Public documentation: https://docs.github.com/en/code-security/supply-chain-security/understanding-your-software-supply-chain/about-dependency-review#dependency-review-enforcement
name: 'Dependency Review'
on: [pull_request]

permissions:
contents: read

jobs:
dependency-review:
runs-on: ubuntu-latest
steps:
- name: 'Checkout Repository'
uses: actions/checkout@v3
- name: 'Dependency Review'
uses: actions/dependency-review-action@v3
22 changes: 0 additions & 22 deletions .github/workflows/label.yml

This file was deleted.

39 changes: 39 additions & 0 deletions .github/workflows/python-app.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-python

name: Python application

on:
push:
branches: [ "main" ]
pull_request:
branches: [ "main" ]

permissions:
contents: read

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v3
- name: Set up Python 3.10
uses: actions/setup-python@v3
with:
python-version: "3.10"
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install flake8 pytest
if [ -f requirements.txt ]; then pip install -r requirements.txt; fi
- name: Lint with flake8
run: |
# stop the build if there are Python syntax errors or undefined names
flake8 . --count --select=E9,F63,F7,F82 --show-source --statistics
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Main code Updated
run: |
python Check_MCUS.py
24 changes: 24 additions & 0 deletions Check_MCUS.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import hashlib
import sys

def calculate_hash(file_path):
with open(file_path, 'rb') as file:
bytes = file.read()
readable_hash = hashlib.sha256(bytes).hexdigest()
return readable_hash

def compare_files(file1, file2):
file1_hash = calculate_hash(file1)
file2_hash = calculate_hash(file2)

if file1_hash == file2_hash:
print(f"The files {file1} and {file2} are identical.")
else:
print(f"The files {file1} and {file2} are different.")
sys.exit(1)

# Replace with your file paths
file1 = "Model_T&T.ipynb"
file2 = "BETA_E_Model_T&T.ipynb"

compare_files(file1, file2)
35 changes: 17 additions & 18 deletions Model_T&T.ipynb

Large diffs are not rendered by default.

2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
<img src="https://img.shields.io/badge/Python-FFD43B?style=for-the-badge&logo=python&logoColor=blue"/> <img src="https://img.shields.io/badge/TensorFlow-FF6F00?style=for-the-badge&logo=tensorflow&logoColor=white"/> <img src="https://img.shields.io/badge/Keras-FF0000?style=for-the-badge&logo=keras&logoColor=white"/>

[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![CodeQL](https://github.com/Aydinhamedi/Pneumonia-Detection-Ai/actions/workflows/codeql.yml/badge.svg?branch=main)](https://github.com/Aydinhamedi/Pneumonia-Detection-Ai/actions/workflows/codeql.yml)

### This project uses a deep learning model built with the TensorFlow framework to detect pneumonia in X-ray images. The model architecture is based on the EfficientNetB7 model, which has achieved an accuracy of approximately 97.12% (97.11538%) on our test data. This high accuracy rate is one of the strengths of our AI model.
> [!IMPORTANT]
> The code that have achived the highest acc is `backup/V6/Model_T&T.ipynb`.\
Expand Down

0 comments on commit 855117b

Please sign in to comment.