Skip to content

Conversation

@yurekami
Copy link

Summary

  • Updates PyTorch minimum version from 2.0.1 to 2.1.0
  • Removes unconditional print statement that pollutes stdout
  • Adds __version__ for version tracking

Related Issue

Fixes #220

Problem

The requirements.txt had torch==2.0.1 pinned, but the transformers library requires PyTorch >= 2.1. This caused installation failures:

Disabling PyTorch because PyTorch >= 2.1 is required but found 2.0.1+cu117
None of PyTorch, TensorFlow >= 2.0, or Flax have been found...

Additionally, janus/__init__.py printed a message unconditionally on import:

Python version is above 3.10, patching the collections module.

This polluted stdout and could interfere with output parsing.

Changes

requirements.txt

-torch==2.0.1
+torch>=2.1.0

pyproject.toml

-    "torch>=2.0.1",
+    "torch>=2.1.0",

janus/__init__.py

  • Added __version__ = "1.0.0"
  • Removed print() statement, keeping the compatibility patch with a comment

Test plan

  • Verify Python syntax is valid
  • Verify pyproject.toml is valid
  • Test installation with pip install .
  • Verify import works without stdout pollution

🤖 Generated with Claude Code

- Update torch requirement from ==2.0.1 to >=2.1.0 in requirements.txt
- Update torch requirement from >=2.0.1 to >=2.1.0 in pyproject.toml
- Remove unconditional print statement in janus/__init__.py
- Add __version__ = "1.0.0" for version tracking

The transformers library requires PyTorch >= 2.1, so the previous
torch==2.0.1 pin was causing installation failures as reported in deepseek-ai#220.

Also removes the print() statement that was polluting stdout when
importing the module, replacing it with a comment explaining the
collections compatibility patch.

Fixes deepseek-ai#220

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

当前项目 requirements.txt 的依赖声明无法运行模型,希望能尽快更新依赖说明

1 participant