ffdn

Implementation for Enhancing Tampered Text Detection Through Frequency Feature Fusion and Decomposition

https://github.com/rapisurazurite/ffdn

Science Score: 67.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
    Found 1 DOI reference(s) in README
  • Academic publication links
    Links to: springer.com
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (11.4%) to scientific vocabulary
Last synced: 9 months ago · JSON representation ·

Repository

Implementation for Enhancing Tampered Text Detection Through Frequency Feature Fusion and Decomposition

Basic Info
  • Host: GitHub
  • Owner: Rapisurazurite
  • License: apache-2.0
  • Language: C
  • Default Branch: main
  • Size: 71.3 MB
Statistics
  • Stars: 9
  • Watchers: 1
  • Forks: 0
  • Open Issues: 0
  • Releases: 1
Created over 1 year ago · Last pushed over 1 year ago
Metadata Files
Readme License Citation

readme.md

Enhancing Tampered Text Detection through Frequency Feature Fusion and Decomposition

This repository is official implementation for Enhancing Tampered Text Detection Through Frequency Feature Fusion and Decomposition, ECCV 2024.

We introduce a Feature Fusion and Decomposition Network (FFDN) that combines a Visual Enhancement Module (VEM) with a Wavelet-like Frequency Enhancement (WFE). The VEM makes tampering traces visible while preserving the integrity of original RGB features using zero-initialized convolutions. Meanwhile, the WFE decomposes the features to explicitly retain high-frequency details that are often overlooked during downsampling, focusing on small but critical tampering clues. assets/framework.png

Prepare Dataset

  1. download the dataset from DocTamper
  2. Link the dataset to ./data/DocTamperV1/unzip_files.

Your folder structure should look like this: ```text data └── DocTamperV1 ├── unzipfiles │ ├── DocTamperV1-TrainingSet │ ├── DocTamperV1-TestingSet │ ├── DocTamperV1-FCD │ └── DocTamperV1-SCD ├── pks │ ├── DocTamperV1-TestingSet75.pk │ ├── DocTamperV1-FCD75.pk │ └── DocTamperV1-SCD75.pk └── processed ├── train.txt ├── val.txt ├── fcd.txt └── scd.txt

```

Getting Started

Installations

To install FFDN, follow these steps:

```bash

install jpegio

cd FFDN/libs/jpegio pip install -r requirements.txt python setup.py install

install mmsegmentation

cd ../../ pip install -r requirements.txt ```

Inference

Run the demo in inference.ipynb

Train and Evaluate

```bash export GPUNUMS=4 export PRETRAINEDMODEL=work_dirs/FFDN/FFDN.pth

bash tools/disttrainval.sh workconfig/FFDN/FFDN.py ${GPUNUMS} bash tools/disttestdocTamperlmdb.sh workconfig/FFDN/FFDN.py ${PRETRAINEDMODEL} ${GPUNUMS} ```

Note

For fair comparison, we replace 3 times compression with 1 time compression, because the Doctamper project actually compresses 1 time due to a code implementation error. For more details, please refer to jpegcompressvis.ipynb.

Acknowledgement

This project builds upon several open-source projects and datasets:

MMSeg: We leverage the MMSegmentation framework for our model implementation and training pipeline. Their modular design and extensive tools greatly facilitated our research.

DocTamper: We utilize the DocTamper dataset and build upon their baseline methods. Their work in document tampering detection has been instrumental in advancing this field.

JPEGIO: We use the JPEG IO library for efficient JPEG image processing, which is crucial for our frequency domain analysis.

We express our sincere gratitude to the developers and researchers behind these projects. Their contributions to the open-source community have been invaluable to our research.

Citation

If you find this work useful in your research, please consider citing:

bibtex @inproceedings{chen2024enhancing, title={Enhancing Tampered Text Detection Through Frequency Feature Fusion and Decomposition}, author={Chen, Zhongxi and Chen, Shen and Yao, Taiping and Sun, Ke and Ding, Shouhong and Lin, Xianming and Cao, Liujuan and Ji, Rongrong}, booktitle={European Conference on Computer Vision}, pages={200--217}, year={2024}, organization={Springer} }

Owner

  • Name: Lazurite
  • Login: Rapisurazurite
  • Kind: user

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
  - name: "MMSegmentation Contributors"
title: "OpenMMLab Semantic Segmentation Toolbox and Benchmark"
date-released: 2020-07-10
url: "https://github.com/open-mmlab/mmsegmentation"
license: Apache-2.0

GitHub Events

Total
  • Create event: 2
  • Issues event: 9
  • Release event: 1
  • Watch event: 15
  • Issue comment event: 16
  • Push event: 3
Last Year
  • Create event: 2
  • Issues event: 9
  • Release event: 1
  • Watch event: 15
  • Issue comment event: 16
  • Push event: 3

Dependencies

requirements/albu.txt pypi
  • albumentations >=0.3.2
requirements/docs.txt pypi
  • docutils ==0.16.0
  • myst-parser *
  • sphinx ==4.0.2
  • sphinx_copybutton *
  • sphinx_markdown_tables *
  • urllib3 <2.0.0
requirements/mminstall.txt pypi
  • mmcv >=2.0.0rc4
  • mmengine >=0.5.0,<1.0.0
requirements/optional.txt pypi
  • cityscapesscripts *
  • nibabel *
requirements/readthedocs.txt pypi
  • mmcv >=2.0.0rc1,<2.1.0
  • mmengine >=0.4.0,<1.0.0
  • prettytable *
  • scipy *
  • torch *
  • torchvision *
requirements/runtime.txt pypi
  • matplotlib *
  • numpy *
  • packaging *
  • prettytable *
  • scipy *
requirements/tests.txt pypi
  • codecov * test
  • flake8 * test
  • interrogate * test
  • pytest * test
  • xdoctest >=0.10.0 test
  • yapf * test
libs/jpegio/pyproject.toml pypi
libs/jpegio/requirements.txt pypi
  • Cython *
  • numpy *
libs/jpegio/requirements_dev.txt pypi
  • scipy * development
libs/jpegio/setup.py pypi
requirements.txt pypi
setup.py pypi