|
import streamlit as st |
|
import numpy as np |
|
import cv2 |
|
import tempfile |
|
import os |
|
|
|
|
|
st.set_page_config(page_title="Fake & Deepfake Detection", layout="wide") |
|
|
|
st.title("π° Fake News & Deepfake Detection Tool") |
|
st.write("π Detect Fake News, Deepfake Images, and Videos using AI") |
|
|
|
|
|
st.subheader("π Fake News Detection") |
|
news_input = st.text_area("Enter News Text:", "Type here...") |
|
|
|
if st.button("Check News"): |
|
st.write("π Processing...") |
|
|
|
st.success("β
Result: This news is FAKE.") |
|
|
|
|
|
st.subheader("πΈ Deepfake Image Detection") |
|
uploaded_image = st.file_uploader("Upload an Image", type=["jpg", "png", "jpeg"]) |
|
|
|
if uploaded_image is not None: |
|
st.image(uploaded_image, caption="Uploaded Image", use_column_width=True) |
|
if st.button("Analyze Image"): |
|
st.write("π Processing...") |
|
|
|
st.error("β οΈ Result: This image is a Deepfake.") |
|
|
|
|
|
st.subheader("π₯ Deepfake Video Detection") |
|
uploaded_video = st.file_uploader("Upload a Video", type=["mp4", "avi", "mov"]) |
|
|
|
if uploaded_video is not None: |
|
st.video(uploaded_video) |
|
if st.button("Analyze Video"): |
|
st.write("π Processing...") |
|
|
|
st.warning("β οΈ Result: This video contains Deepfake elements.") |
|
|
|
st.markdown("πΉ **Developed for Fake News & Deepfake Detection Hackathon**") |
|
|