Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
146 changes: 146 additions & 0 deletions docs/_static/custom.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,146 @@
/* Custom CSS for MarkDiffusion Documentation */

/* Increase sidebar width and ensure no gap */
.wy-nav-side {
width: 350px !important;
left: 0 !important;
}

/* Ensure sidebar top section (purple area) matches width */
.wy-side-nav-search {
width: 350px !important;
box-sizing: border-box !important;
margin: 0 !important;
padding: 1.618em !important;
}

/* Ensure menu items match sidebar width */
.wy-menu.wy-menu-vertical {
width: 350px !important;
box-sizing: border-box !important;
margin: 0 !important;
padding: 0 !important;
}

/* Ensure highlighted/current items fill the width */
.wy-menu-vertical li.current {
width: 350px !important;
}

.wy-menu-vertical li.current > a {
width: 100% !important;
box-sizing: border-box !important;
}

/* Hide sidebar scrollbar and prevent it from taking space */
.wy-side-scroll {
overflow-y: scroll !important;
scrollbar-width: none !important; /* Firefox */
-ms-overflow-style: none !important; /* IE and Edge */
width: 100% !important;
}

.wy-side-scroll::-webkit-scrollbar {
display: none !important; /* Chrome, Safari and Opera */
width: 0 !important;
height: 0 !important;
}

/* Ensure the navigation container fills the entire sidebar */
.wy-side-nav-search,
.wy-menu.wy-menu-vertical {
overflow-x: hidden !important;
}

/* Adjust content area to accommodate wider sidebar */
.wy-nav-content-wrap {
margin-left: 350px !important;
}

/* Increase max width of content area to use more screen space */
.wy-nav-content {
max-width: 1200px !important;
}

/* Make the overall page wider on large screens */
@media screen and (min-width: 1400px) {
.wy-nav-side {
width: 380px !important;
left: 0 !important;
}

.wy-side-nav-search {
width: 380px !important;
box-sizing: border-box !important;
}

.wy-menu.wy-menu-vertical {
width: 380px !important;
box-sizing: border-box !important;
}

.wy-menu-vertical li.current {
width: 380px !important;
}

.wy-nav-content-wrap {
margin-left: 380px !important;
}

.wy-nav-content {
max-width: 1400px !important;
}
}

/* Ensure sidebar text wraps properly with the increased width */
.wy-menu-vertical li.toctree-l1 > a,
.wy-menu-vertical li.toctree-l2 > a,
.wy-menu-vertical li.toctree-l3 > a {
white-space: normal !important;
line-height: 1.4 !important;
padding: 0.4045em 1.618em !important;
width: 100% !important;
box-sizing: border-box !important;
}

/* Add slight padding to long navigation items */
.wy-menu-vertical li.current > a {
padding: 0.4045em 1.618em !important;
width: 100% !important;
box-sizing: border-box !important;
}

/* Ensure all list items fill the width */
.wy-menu-vertical li {
width: 100% !important;
}

/* Ensure current item background fills the width */
.wy-menu-vertical li.current > a,
.wy-menu-vertical li.on a,
.wy-menu-vertical li.current > a:hover,
.wy-menu-vertical li.on a:hover {
background: #e3e3e3 !important;
width: 100% !important;
box-sizing: border-box !important;
}

/* Ensure nested menu items also fill width */
.wy-menu-vertical ul {
width: 100% !important;
}

.wy-menu-vertical ul li a {
width: 100% !important;
box-sizing: border-box !important;
}

/* Remove purple color from visited links in content area */
.wy-nav-content a:visited {
color: #2980B9 !important;
}

.wy-nav-content a:link {
color: #2980B9 !important;
}

5 changes: 5 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,11 @@
# so a file named "default.css" will overwrite the builtin "default.css".
html_static_path = ['_static']

# Custom CSS files
html_css_files = [
'custom.css',
]

# Custom sidebar templates, must be a dictionary that maps document names
# to template names.
html_sidebars = {
Expand Down
19 changes: 7 additions & 12 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ MarkDiffusion Documentation
:target: https://colab.research.google.com/drive/1N1C9elDAB5zwF4FxKKYMCqR3eSpCSqAW?usp=sharing
:alt: Colab

.. image:: https://img.shields.io/badge/Readthedocs-%2300A89C?style=for-the-badge&logo=readthedocs&logoColor=%238CA1AF
:target: https://markdiffusion.readthedocs.io
:alt: DOC

.. image:: https://img.shields.io/badge/PYPI-%23193440?style=for-the-badge&logo=pypi&logoColor=%233775A9
:target: https://pypi.org/project/markdiffusion
:alt: PYPI
Expand Down Expand Up @@ -64,15 +60,20 @@ Key Features
:width: 100%
:align: center

|
|

A Quick Example of Generating and Detecting Watermarked Image via MarkDiffusion Toolkit
---------------
-----------------------------------------------------------------------------------------

.. image:: ../img/A_Quick_Example.png
:alt: A quick example of generating and detecting watermarked image via MarkDiffusion toolkit
:width: 100%
:align: center

|
|

Documentation Contents
----------------------

Expand All @@ -84,7 +85,7 @@ Documentation Contents

.. toctree::
:maxdepth: 2
:caption: Background Information and
:caption: Background Info &
Detailed Guidance

user_guide/algorithms
Expand Down Expand Up @@ -117,10 +118,4 @@ Documentation Contents
citation
resources

Indices and tables
==================

* :ref:`genindex`
* :ref:`modindex`
* :ref:`search`

11 changes: 5 additions & 6 deletions docs/quickstart.rst
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
Quick Start
===========
.. _quickstart:

Google Colab Demo
-----------------
=================

If you're interested in trying out MarkDiffusion without installing anything, you can use
`Google Colab <https://colab.research.google.com/drive/1N1C9elDAB5zwF4FxKKYMCqR3eSpCSqAW?usp=sharing>`_
to see how it works.

Installation
------------
============

**(Recommended)** We released PyPI package for MarkDiffusion. You can install it directly with pip:

Expand All @@ -35,7 +34,7 @@ conda-forge package, which can be installed with the following commands:
be included in the release. You will need to install those separately if necessary.

How to Use the Toolkit
----------------------
======================

After installation, there are two ways to use MarkDiffusion:

Expand Down Expand Up @@ -148,7 +147,7 @@ via the markdiffusion libraryβ€”please review it for guidance. Here's a quick ex
print(detection_result)

Next Steps
----------
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Now that you're familiar with the basics, explore more:

Expand Down
12 changes: 5 additions & 7 deletions docs/test_system/comprehensive_test.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ This comprehensive test module is located in the ``test/`` directory.
Test Coverage Statistics
------------------------

- **Total Test Cases**: 454 unit tests
- **Code Coverage**: Approximately 90%
- **Total Test Cases**: 658 unit tests
- **Code Coverage**: Approximately 95%
- **Coverage Scope**: Nearly all functional modules
- **Uncovered Code**: Primarily exception handling and edge case logic

Expand All @@ -19,8 +19,6 @@ Test Structure

The test suite is organized into several test files:

Core Functionality Tests
~~~~~~~~~~~~~~~~~~~~~~~~

**test_watermark_algorithms.py**
Tests for initialization, generation, detection, inversion, and visualization of all watermark algorithms.
Expand All @@ -31,9 +29,6 @@ Core Functionality Tests
**test_dataset.py**
Tests for dataset classes (StableDiffusionPromptsDataset, MSCOCODataset, VBenchDataset).

Utility and Module Tests
~~~~~~~~~~~~~~~~~~~~~~~~~

**test_utils.py**
Tests for utility functions used throughout the toolkit.

Expand All @@ -46,6 +41,9 @@ Utility and Module Tests
**test_video_editor.py**
Tests for video editing modules.

**test_edge_cases.py**
Tests for some edge cases.

Running the Tests
-----------------

Expand Down