Files
chai-lab/tests/test_cif_utils.py
Olamide Isreal f971fd0e21 Initial commit: Chai-1 protein structure prediction pipeline for WES
- Nextflow pipeline using chai1 Docker image from Harbor
- S3-based input/output paths (s3://omic/eureka/chai-lab/)
- GPU-accelerated protein folding with MSA support

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
2026-03-16 12:55:08 +01:00

25 lines
696 B
Python
Executable File

# Copyright (c) 2024 Chai Discovery, Inc.
# Licensed under the Apache License, Version 2.0.
# See the LICENSE file for details.
import pytest
from chai_lab.data.io.cif_utils import get_chain_letter
def test_get_chain_letter():
with pytest.raises(AssertionError):
get_chain_letter(0)
assert get_chain_letter(1) == "A"
assert get_chain_letter(26) == "Z"
assert get_chain_letter(27) == "a"
assert get_chain_letter(52) == "z"
assert get_chain_letter(53) == "AA"
assert get_chain_letter(54) == "AB"
# For one-letter codes, there are 26 + 26 = 52 codes
# For two-letter codes, there are 52 * 52 codes
assert get_chain_letter(52 * 52 + 52) == "zz"