mirror of
https://github.com/Wan-Video/Wan2.1.git
synced 2026-01-15 02:25:40 +00:00
Compare commits
6 Commits
e85295b588
...
c56c3d6ae2
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c56c3d6ae2 | ||
|
|
ae487cc653 | ||
|
|
854bd88e7f | ||
|
|
8177ee5bc6 | ||
|
|
f134d60bcc | ||
|
|
608d98e833 |
@ -36,6 +36,9 @@ In this repository, we present **Wan2.1**, a comprehensive and open suite of vid
|
|||||||
|
|
||||||
## Community Works
|
## Community Works
|
||||||
If your work has improved **Wan2.1** and you would like more people to see it, please inform us.
|
If your work has improved **Wan2.1** and you would like more people to see it, please inform us.
|
||||||
|
- [Video-As-Prompt](https://github.com/bytedance/Video-As-Prompt), the first unified semantic-controlled video generation model based on **Wan2.1-14B-I2V** with a Mixture-of-Transformers architecture and in-context controls (e.g., concept, style, motion, camera). Refer to the [project page](https://bytedance.github.io/Video-As-Prompt/) for more examples.
|
||||||
|
- [LightX2V](https://github.com/ModelTC/LightX2V), a lightweight and efficient video generation framework that integrates **Wan2.1** and **Wan2.2**, supports multiple engineering acceleration techniques for fast inference, which can run on RTX 5090 and RTX 4060 (8GB VRAM).
|
||||||
|
- [DriVerse](https://github.com/shalfun/DriVerse), an autonomous driving world model based on **Wan2.1-14B-I2V**, generates future driving videos conditioned on any scene frame and given trajectory. Refer to the [project page](https://github.com/shalfun/DriVerse/tree/main) for more examples.
|
||||||
- [Training-Free-WAN-Editing](https://github.com/KyujinHan/Awesome-Training-Free-WAN2.1-Editing), built on **Wan2.1-T2V-1.3B**, allows training-free video editing with image-based training-free methods, such as [FlowEdit](https://arxiv.org/abs/2412.08629) and [FlowAlign](https://arxiv.org/abs/2505.23145).
|
- [Training-Free-WAN-Editing](https://github.com/KyujinHan/Awesome-Training-Free-WAN2.1-Editing), built on **Wan2.1-T2V-1.3B**, allows training-free video editing with image-based training-free methods, such as [FlowEdit](https://arxiv.org/abs/2412.08629) and [FlowAlign](https://arxiv.org/abs/2505.23145).
|
||||||
- [Wan-Move](https://github.com/ali-vilab/Wan-Move), accepted to NeurIPS 2025, a framework that brings **Wan2.1-I2V-14B** to SOTA fine-grained, point-level motion control! Refer to [their project page](https://wan-move.github.io/) for more information.
|
- [Wan-Move](https://github.com/ali-vilab/Wan-Move), accepted to NeurIPS 2025, a framework that brings **Wan2.1-I2V-14B** to SOTA fine-grained, point-level motion control! Refer to [their project page](https://wan-move.github.io/) for more information.
|
||||||
- [EchoShot](https://github.com/JoHnneyWang/EchoShot), a native multi-shot portrait video generation model based on **Wan2.1-T2V-1.3B**, allows generation of multiple video clips featuring the same character as well as highly flexible content controllability. Refer to [their project page](https://johnneywang.github.io/EchoShot-webpage/) for more information.
|
- [EchoShot](https://github.com/JoHnneyWang/EchoShot), a native multi-shot portrait video generation model based on **Wan2.1-T2V-1.3B**, allows generation of multiple video clips featuring the same character as well as highly flexible content controllability. Refer to [their project page](https://johnneywang.github.io/EchoShot-webpage/) for more information.
|
||||||
|
|||||||
37
calculator.py
Normal file
37
calculator.py
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
import argparse
|
||||||
|
|
||||||
|
def add(x, y):
|
||||||
|
"""Adds two numbers together."""
|
||||||
|
return x + y
|
||||||
|
|
||||||
|
def subtract(x, y):
|
||||||
|
"""Subtracts two numbers."""
|
||||||
|
return x - y
|
||||||
|
|
||||||
|
def multiply(x, y):
|
||||||
|
"""Multiplies two numbers."""
|
||||||
|
return x * y
|
||||||
|
|
||||||
|
def divide(x, y):
|
||||||
|
"""Divides two numbers."""
|
||||||
|
if y == 0:
|
||||||
|
raise ValueError("Cannot divide by zero.")
|
||||||
|
return x / y
|
||||||
|
|
||||||
|
if __name__ == "__main__":
|
||||||
|
parser = argparse.ArgumentParser(description="A simple command-line calculator.")
|
||||||
|
parser.add_argument("x", type=float, help="The first number.")
|
||||||
|
parser.add_argument("operation", choices=["+", "-", "*", "/"], help="The operation to perform.")
|
||||||
|
parser.add_argument("y", type=float, help="The second number.")
|
||||||
|
args = parser.parse_args()
|
||||||
|
|
||||||
|
if args.operation == "+":
|
||||||
|
result = add(args.x, args.y)
|
||||||
|
elif args.operation == "-":
|
||||||
|
result = subtract(args.x, args.y)
|
||||||
|
elif args.operation == "*":
|
||||||
|
result = multiply(args.x, args.y)
|
||||||
|
elif args.operation == "/":
|
||||||
|
result = divide(args.x, args.y)
|
||||||
|
|
||||||
|
print(f"Result: {result}")
|
||||||
29
test_calculator.py
Normal file
29
test_calculator.py
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
import unittest
|
||||||
|
from calculator import add, subtract, multiply, divide
|
||||||
|
|
||||||
|
class TestCalculator(unittest.TestCase):
|
||||||
|
|
||||||
|
def test_add(self):
|
||||||
|
self.assertEqual(add(2, 3), 5)
|
||||||
|
self.assertEqual(add(-1, 1), 0)
|
||||||
|
self.assertEqual(add(-1, -1), -2)
|
||||||
|
|
||||||
|
def test_subtract(self):
|
||||||
|
self.assertEqual(subtract(3, 2), 1)
|
||||||
|
self.assertEqual(subtract(-1, 1), -2)
|
||||||
|
self.assertEqual(subtract(-1, -1), 0)
|
||||||
|
|
||||||
|
def test_multiply(self):
|
||||||
|
self.assertEqual(multiply(2, 3), 6)
|
||||||
|
self.assertEqual(multiply(-1, 1), -1)
|
||||||
|
self.assertEqual(multiply(-1, -1), 1)
|
||||||
|
|
||||||
|
def test_divide(self):
|
||||||
|
self.assertEqual(divide(6, 3), 2)
|
||||||
|
self.assertEqual(divide(-1, 1), -1)
|
||||||
|
self.assertEqual(divide(-1, -1), 1)
|
||||||
|
with self.assertRaises(ValueError):
|
||||||
|
divide(1, 0)
|
||||||
|
|
||||||
|
if __name__ == '__main__':
|
||||||
|
unittest.main()
|
||||||
Loading…
Reference in New Issue
Block a user