From 1c957b5d7dba149bae8abf04b3ece6381d993688 Mon Sep 17 00:00:00 2001 From: by321 Date: Mon, 11 Dec 2023 16:18:18 -0800 Subject: [PATCH] test file with duplicate keys in header --- safetensors_file.py | 1 + test/duplicate_keys_in_header.safetensors | Bin 0 -> 374 bytes 2 files changed, 1 insertion(+) create mode 100644 test/duplicate_keys_in_header.safetensors diff --git a/safetensors_file.py b/safetensors_file.py index b584def..782a1eb 100644 --- a/safetensors_file.py +++ b/safetensors_file.py @@ -43,6 +43,7 @@ def close_file(self): self.f=None self.filename="" + #test file: duplicate_keys_in_header.safetensors def _CheckDuplicateHeaderKeys(self): def parse_object_pairs(pairs): return [k for k,_ in pairs] diff --git a/test/duplicate_keys_in_header.safetensors b/test/duplicate_keys_in_header.safetensors new file mode 100644 index 0000000000000000000000000000000000000000..81afad592b901d3caafdc61d6d793488bde7eaf8 GIT binary patch literal 374 zcmYdbWB`L|rR>y714AXNYNeEt%7RoSE2U5iB^{;Wj6@J8+DOMZR!1o%u_Q4*KP{~| zwWJs*XrN;jTdPArry-_3GaYln`iyk2=rq@{gy}TK=~hE*Zne}gG=gb0!L1e3v4%j0 a7{hepu@s9=V;w`2*xFhJAb^B2j06C;J!_=^ literal 0 HcmV?d00001