Add files using upload-large-folder tool
Browse files- benchmark/IOAI/IOAI-2025/LICENSE +395 -0
- benchmark/IOAI/IOAI-2025/README.md +108 -0
- benchmark/IOAI/IOAI-2025/requirements.txt +521 -0
- benchmark/IOAI/IOAI2025/.gitattributes +220 -0
- benchmark/IOAI/IOAI2025/Individual-Contest/Antique/Antique.ipynb +236 -0
- benchmark/IOAI/IOAI2025/Individual-Contest/Antique/score.json +1 -0
- benchmark/IOAI/IOAI2025/Individual-Contest/Chicken_Counting/Chicken_Counting.ipynb +619 -0
- benchmark/IOAI/IOAI2025/Individual-Contest/Concepts/Concepts.ipynb +826 -0
- benchmark/IOAI/IOAI2025/Individual-Contest/Concepts/llm_proxy_tutorial.ipynb +263 -0
- benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v12.json +57 -0
- benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v13.json +31 -0
- benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v14.json +90 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherContextSettings.cs +113 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherContextSettings.cs.meta +11 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherTestRunSettings.cs +19 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherTestRunSettings.cs.meta +11 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlaymodeLauncher.cs +133 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlaymodeLauncher.cs.meta +11 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PostbuildCleanupAttributeFinder.cs +9 -0
- benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PostbuildCleanupAttributeFinder.cs.meta +11 -0
benchmark/IOAI/IOAI-2025/LICENSE
ADDED
|
@@ -0,0 +1,395 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
Attribution 4.0 International
|
| 2 |
+
|
| 3 |
+
=======================================================================
|
| 4 |
+
|
| 5 |
+
Creative Commons Corporation ("Creative Commons") is not a law firm and
|
| 6 |
+
does not provide legal services or legal advice. Distribution of
|
| 7 |
+
Creative Commons public licenses does not create a lawyer-client or
|
| 8 |
+
other relationship. Creative Commons makes its licenses and related
|
| 9 |
+
information available on an "as-is" basis. Creative Commons gives no
|
| 10 |
+
warranties regarding its licenses, any material licensed under their
|
| 11 |
+
terms and conditions, or any related information. Creative Commons
|
| 12 |
+
disclaims all liability for damages resulting from their use to the
|
| 13 |
+
fullest extent possible.
|
| 14 |
+
|
| 15 |
+
Using Creative Commons Public Licenses
|
| 16 |
+
|
| 17 |
+
Creative Commons public licenses provide a standard set of terms and
|
| 18 |
+
conditions that creators and other rights holders may use to share
|
| 19 |
+
original works of authorship and other material subject to copyright
|
| 20 |
+
and certain other rights specified in the public license below. The
|
| 21 |
+
following considerations are for informational purposes only, are not
|
| 22 |
+
exhaustive, and do not form part of our licenses.
|
| 23 |
+
|
| 24 |
+
Considerations for licensors: Our public licenses are
|
| 25 |
+
intended for use by those authorized to give the public
|
| 26 |
+
permission to use material in ways otherwise restricted by
|
| 27 |
+
copyright and certain other rights. Our licenses are
|
| 28 |
+
irrevocable. Licensors should read and understand the terms
|
| 29 |
+
and conditions of the license they choose before applying it.
|
| 30 |
+
Licensors should also secure all rights necessary before
|
| 31 |
+
applying our licenses so that the public can reuse the
|
| 32 |
+
material as expected. Licensors should clearly mark any
|
| 33 |
+
material not subject to the license. This includes other CC-
|
| 34 |
+
licensed material, or material used under an exception or
|
| 35 |
+
limitation to copyright. More considerations for licensors:
|
| 36 |
+
wiki.creativecommons.org/Considerations_for_licensors
|
| 37 |
+
|
| 38 |
+
Considerations for the public: By using one of our public
|
| 39 |
+
licenses, a licensor grants the public permission to use the
|
| 40 |
+
licensed material under specified terms and conditions. If
|
| 41 |
+
the licensor's permission is not necessary for any reason--for
|
| 42 |
+
example, because of any applicable exception or limitation to
|
| 43 |
+
copyright--then that use is not regulated by the license. Our
|
| 44 |
+
licenses grant only permissions under copyright and certain
|
| 45 |
+
other rights that a licensor has authority to grant. Use of
|
| 46 |
+
the licensed material may still be restricted for other
|
| 47 |
+
reasons, including because others have copyright or other
|
| 48 |
+
rights in the material. A licensor may make special requests,
|
| 49 |
+
such as asking that all changes be marked or described.
|
| 50 |
+
Although not required by our licenses, you are encouraged to
|
| 51 |
+
respect those requests where reasonable. More considerations
|
| 52 |
+
for the public:
|
| 53 |
+
wiki.creativecommons.org/Considerations_for_licensees
|
| 54 |
+
|
| 55 |
+
=======================================================================
|
| 56 |
+
|
| 57 |
+
Creative Commons Attribution 4.0 International Public License
|
| 58 |
+
|
| 59 |
+
By exercising the Licensed Rights (defined below), You accept and agree
|
| 60 |
+
to be bound by the terms and conditions of this Creative Commons
|
| 61 |
+
Attribution 4.0 International Public License ("Public License"). To the
|
| 62 |
+
extent this Public License may be interpreted as a contract, You are
|
| 63 |
+
granted the Licensed Rights in consideration of Your acceptance of
|
| 64 |
+
these terms and conditions, and the Licensor grants You such rights in
|
| 65 |
+
consideration of benefits the Licensor receives from making the
|
| 66 |
+
Licensed Material available under these terms and conditions.
|
| 67 |
+
|
| 68 |
+
|
| 69 |
+
Section 1 -- Definitions.
|
| 70 |
+
|
| 71 |
+
a. Adapted Material means material subject to Copyright and Similar
|
| 72 |
+
Rights that is derived from or based upon the Licensed Material
|
| 73 |
+
and in which the Licensed Material is translated, altered,
|
| 74 |
+
arranged, transformed, or otherwise modified in a manner requiring
|
| 75 |
+
permission under the Copyright and Similar Rights held by the
|
| 76 |
+
Licensor. For purposes of this Public License, where the Licensed
|
| 77 |
+
Material is a musical work, performance, or sound recording,
|
| 78 |
+
Adapted Material is always produced where the Licensed Material is
|
| 79 |
+
synched in timed relation with a moving image.
|
| 80 |
+
|
| 81 |
+
b. Adapter's License means the license You apply to Your Copyright
|
| 82 |
+
and Similar Rights in Your contributions to Adapted Material in
|
| 83 |
+
accordance with the terms and conditions of this Public License.
|
| 84 |
+
|
| 85 |
+
c. Copyright and Similar Rights means copyright and/or similar rights
|
| 86 |
+
closely related to copyright including, without limitation,
|
| 87 |
+
performance, broadcast, sound recording, and Sui Generis Database
|
| 88 |
+
Rights, without regard to how the rights are labeled or
|
| 89 |
+
categorized. For purposes of this Public License, the rights
|
| 90 |
+
specified in Section 2(b)(1)-(2) are not Copyright and Similar
|
| 91 |
+
Rights.
|
| 92 |
+
|
| 93 |
+
d. Effective Technological Measures means those measures that, in the
|
| 94 |
+
absence of proper authority, may not be circumvented under laws
|
| 95 |
+
fulfilling obligations under Article 11 of the WIPO Copyright
|
| 96 |
+
Treaty adopted on December 20, 1996, and/or similar international
|
| 97 |
+
agreements.
|
| 98 |
+
|
| 99 |
+
e. Exceptions and Limitations means fair use, fair dealing, and/or
|
| 100 |
+
any other exception or limitation to Copyright and Similar Rights
|
| 101 |
+
that applies to Your use of the Licensed Material.
|
| 102 |
+
|
| 103 |
+
f. Licensed Material means the artistic or literary work, database,
|
| 104 |
+
or other material to which the Licensor applied this Public
|
| 105 |
+
License.
|
| 106 |
+
|
| 107 |
+
g. Licensed Rights means the rights granted to You subject to the
|
| 108 |
+
terms and conditions of this Public License, which are limited to
|
| 109 |
+
all Copyright and Similar Rights that apply to Your use of the
|
| 110 |
+
Licensed Material and that the Licensor has authority to license.
|
| 111 |
+
|
| 112 |
+
h. Licensor means the individual(s) or entity(ies) granting rights
|
| 113 |
+
under this Public License.
|
| 114 |
+
|
| 115 |
+
i. Share means to provide material to the public by any means or
|
| 116 |
+
process that requires permission under the Licensed Rights, such
|
| 117 |
+
as reproduction, public display, public performance, distribution,
|
| 118 |
+
dissemination, communication, or importation, and to make material
|
| 119 |
+
available to the public including in ways that members of the
|
| 120 |
+
public may access the material from a place and at a time
|
| 121 |
+
individually chosen by them.
|
| 122 |
+
|
| 123 |
+
j. Sui Generis Database Rights means rights other than copyright
|
| 124 |
+
resulting from Directive 96/9/EC of the European Parliament and of
|
| 125 |
+
the Council of 11 March 1996 on the legal protection of databases,
|
| 126 |
+
as amended and/or succeeded, as well as other essentially
|
| 127 |
+
equivalent rights anywhere in the world.
|
| 128 |
+
|
| 129 |
+
k. You means the individual or entity exercising the Licensed Rights
|
| 130 |
+
under this Public License. Your has a corresponding meaning.
|
| 131 |
+
|
| 132 |
+
|
| 133 |
+
Section 2 -- Scope.
|
| 134 |
+
|
| 135 |
+
a. License grant.
|
| 136 |
+
|
| 137 |
+
1. Subject to the terms and conditions of this Public License,
|
| 138 |
+
the Licensor hereby grants You a worldwide, royalty-free,
|
| 139 |
+
non-sublicensable, non-exclusive, irrevocable license to
|
| 140 |
+
exercise the Licensed Rights in the Licensed Material to:
|
| 141 |
+
|
| 142 |
+
a. reproduce and Share the Licensed Material, in whole or
|
| 143 |
+
in part; and
|
| 144 |
+
|
| 145 |
+
b. produce, reproduce, and Share Adapted Material.
|
| 146 |
+
|
| 147 |
+
2. Exceptions and Limitations. For the avoidance of doubt, where
|
| 148 |
+
Exceptions and Limitations apply to Your use, this Public
|
| 149 |
+
License does not apply, and You do not need to comply with
|
| 150 |
+
its terms and conditions.
|
| 151 |
+
|
| 152 |
+
3. Term. The term of this Public License is specified in Section
|
| 153 |
+
6(a).
|
| 154 |
+
|
| 155 |
+
4. Media and formats; technical modifications allowed. The
|
| 156 |
+
Licensor authorizes You to exercise the Licensed Rights in
|
| 157 |
+
all media and formats whether now known or hereafter created,
|
| 158 |
+
and to make technical modifications necessary to do so. The
|
| 159 |
+
Licensor waives and/or agrees not to assert any right or
|
| 160 |
+
authority to forbid You from making technical modifications
|
| 161 |
+
necessary to exercise the Licensed Rights, including
|
| 162 |
+
technical modifications necessary to circumvent Effective
|
| 163 |
+
Technological Measures. For purposes of this Public License,
|
| 164 |
+
simply making modifications authorized by this Section 2(a)
|
| 165 |
+
(4) never produces Adapted Material.
|
| 166 |
+
|
| 167 |
+
5. Downstream recipients.
|
| 168 |
+
|
| 169 |
+
a. Offer from the Licensor -- Licensed Material. Every
|
| 170 |
+
recipient of the Licensed Material automatically
|
| 171 |
+
receives an offer from the Licensor to exercise the
|
| 172 |
+
Licensed Rights under the terms and conditions of this
|
| 173 |
+
Public License.
|
| 174 |
+
|
| 175 |
+
b. No downstream restrictions. You may not offer or impose
|
| 176 |
+
any additional or different terms or conditions on, or
|
| 177 |
+
apply any Effective Technological Measures to, the
|
| 178 |
+
Licensed Material if doing so restricts exercise of the
|
| 179 |
+
Licensed Rights by any recipient of the Licensed
|
| 180 |
+
Material.
|
| 181 |
+
|
| 182 |
+
6. No endorsement. Nothing in this Public License constitutes or
|
| 183 |
+
may be construed as permission to assert or imply that You
|
| 184 |
+
are, or that Your use of the Licensed Material is, connected
|
| 185 |
+
with, or sponsored, endorsed, or granted official status by,
|
| 186 |
+
the Licensor or others designated to receive attribution as
|
| 187 |
+
provided in Section 3(a)(1)(A)(i).
|
| 188 |
+
|
| 189 |
+
b. Other rights.
|
| 190 |
+
|
| 191 |
+
1. Moral rights, such as the right of integrity, are not
|
| 192 |
+
licensed under this Public License, nor are publicity,
|
| 193 |
+
privacy, and/or other similar personality rights; however, to
|
| 194 |
+
the extent possible, the Licensor waives and/or agrees not to
|
| 195 |
+
assert any such rights held by the Licensor to the limited
|
| 196 |
+
extent necessary to allow You to exercise the Licensed
|
| 197 |
+
Rights, but not otherwise.
|
| 198 |
+
|
| 199 |
+
2. Patent and trademark rights are not licensed under this
|
| 200 |
+
Public License.
|
| 201 |
+
|
| 202 |
+
3. To the extent possible, the Licensor waives any right to
|
| 203 |
+
collect royalties from You for the exercise of the Licensed
|
| 204 |
+
Rights, whether directly or through a collecting society
|
| 205 |
+
under any voluntary or waivable statutory or compulsory
|
| 206 |
+
licensing scheme. In all other cases the Licensor expressly
|
| 207 |
+
reserves any right to collect such royalties.
|
| 208 |
+
|
| 209 |
+
|
| 210 |
+
Section 3 -- License Conditions.
|
| 211 |
+
|
| 212 |
+
Your exercise of the Licensed Rights is expressly made subject to the
|
| 213 |
+
following conditions.
|
| 214 |
+
|
| 215 |
+
a. Attribution.
|
| 216 |
+
|
| 217 |
+
1. If You Share the Licensed Material (including in modified
|
| 218 |
+
form), You must:
|
| 219 |
+
|
| 220 |
+
a. retain the following if it is supplied by the Licensor
|
| 221 |
+
with the Licensed Material:
|
| 222 |
+
|
| 223 |
+
i. identification of the creator(s) of the Licensed
|
| 224 |
+
Material and any others designated to receive
|
| 225 |
+
attribution, in any reasonable manner requested by
|
| 226 |
+
the Licensor (including by pseudonym if
|
| 227 |
+
designated);
|
| 228 |
+
|
| 229 |
+
ii. a copyright notice;
|
| 230 |
+
|
| 231 |
+
iii. a notice that refers to this Public License;
|
| 232 |
+
|
| 233 |
+
iv. a notice that refers to the disclaimer of
|
| 234 |
+
warranties;
|
| 235 |
+
|
| 236 |
+
v. a URI or hyperlink to the Licensed Material to the
|
| 237 |
+
extent reasonably practicable;
|
| 238 |
+
|
| 239 |
+
b. indicate if You modified the Licensed Material and
|
| 240 |
+
retain an indication of any previous modifications; and
|
| 241 |
+
|
| 242 |
+
c. indicate the Licensed Material is licensed under this
|
| 243 |
+
Public License, and include the text of, or the URI or
|
| 244 |
+
hyperlink to, this Public License.
|
| 245 |
+
|
| 246 |
+
2. You may satisfy the conditions in Section 3(a)(1) in any
|
| 247 |
+
reasonable manner based on the medium, means, and context in
|
| 248 |
+
which You Share the Licensed Material. For example, it may be
|
| 249 |
+
reasonable to satisfy the conditions by providing a URI or
|
| 250 |
+
hyperlink to a resource that includes the required
|
| 251 |
+
information.
|
| 252 |
+
|
| 253 |
+
3. If requested by the Licensor, You must remove any of the
|
| 254 |
+
information required by Section 3(a)(1)(A) to the extent
|
| 255 |
+
reasonably practicable.
|
| 256 |
+
|
| 257 |
+
4. If You Share Adapted Material You produce, the Adapter's
|
| 258 |
+
License You apply must not prevent recipients of the Adapted
|
| 259 |
+
Material from complying with this Public License.
|
| 260 |
+
|
| 261 |
+
|
| 262 |
+
Section 4 -- Sui Generis Database Rights.
|
| 263 |
+
|
| 264 |
+
Where the Licensed Rights include Sui Generis Database Rights that
|
| 265 |
+
apply to Your use of the Licensed Material:
|
| 266 |
+
|
| 267 |
+
a. for the avoidance of doubt, Section 2(a)(1) grants You the right
|
| 268 |
+
to extract, reuse, reproduce, and Share all or a substantial
|
| 269 |
+
portion of the contents of the database;
|
| 270 |
+
|
| 271 |
+
b. if You include all or a substantial portion of the database
|
| 272 |
+
contents in a database in which You have Sui Generis Database
|
| 273 |
+
Rights, then the database in which You have Sui Generis Database
|
| 274 |
+
Rights (but not its individual contents) is Adapted Material; and
|
| 275 |
+
|
| 276 |
+
c. You must comply with the conditions in Section 3(a) if You Share
|
| 277 |
+
all or a substantial portion of the contents of the database.
|
| 278 |
+
|
| 279 |
+
For the avoidance of doubt, this Section 4 supplements and does not
|
| 280 |
+
replace Your obligations under this Public License where the Licensed
|
| 281 |
+
Rights include other Copyright and Similar Rights.
|
| 282 |
+
|
| 283 |
+
|
| 284 |
+
Section 5 -- Disclaimer of Warranties and Limitation of Liability.
|
| 285 |
+
|
| 286 |
+
a. UNLESS OTHERWISE SEPARATELY UNDERTAKEN BY THE LICENSOR, TO THE
|
| 287 |
+
EXTENT POSSIBLE, THE LICENSOR OFFERS THE LICENSED MATERIAL AS-IS
|
| 288 |
+
AND AS-AVAILABLE, AND MAKES NO REPRESENTATIONS OR WARRANTIES OF
|
| 289 |
+
ANY KIND CONCERNING THE LICENSED MATERIAL, WHETHER EXPRESS,
|
| 290 |
+
IMPLIED, STATUTORY, OR OTHER. THIS INCLUDES, WITHOUT LIMITATION,
|
| 291 |
+
WARRANTIES OF TITLE, MERCHANTABILITY, FITNESS FOR A PARTICULAR
|
| 292 |
+
PURPOSE, NON-INFRINGEMENT, ABSENCE OF LATENT OR OTHER DEFECTS,
|
| 293 |
+
ACCURACY, OR THE PRESENCE OR ABSENCE OF ERRORS, WHETHER OR NOT
|
| 294 |
+
KNOWN OR DISCOVERABLE. WHERE DISCLAIMERS OF WARRANTIES ARE NOT
|
| 295 |
+
ALLOWED IN FULL OR IN PART, THIS DISCLAIMER MAY NOT APPLY TO YOU.
|
| 296 |
+
|
| 297 |
+
b. TO THE EXTENT POSSIBLE, IN NO EVENT WILL THE LICENSOR BE LIABLE
|
| 298 |
+
TO YOU ON ANY LEGAL THEORY (INCLUDING, WITHOUT LIMITATION,
|
| 299 |
+
NEGLIGENCE) OR OTHERWISE FOR ANY DIRECT, SPECIAL, INDIRECT,
|
| 300 |
+
INCIDENTAL, CONSEQUENTIAL, PUNITIVE, EXEMPLARY, OR OTHER LOSSES,
|
| 301 |
+
COSTS, EXPENSES, OR DAMAGES ARISING OUT OF THIS PUBLIC LICENSE OR
|
| 302 |
+
USE OF THE LICENSED MATERIAL, EVEN IF THE LICENSOR HAS BEEN
|
| 303 |
+
ADVISED OF THE POSSIBILITY OF SUCH LOSSES, COSTS, EXPENSES, OR
|
| 304 |
+
DAMAGES. WHERE A LIMITATION OF LIABILITY IS NOT ALLOWED IN FULL OR
|
| 305 |
+
IN PART, THIS LIMITATION MAY NOT APPLY TO YOU.
|
| 306 |
+
|
| 307 |
+
c. The disclaimer of warranties and limitation of liability provided
|
| 308 |
+
above shall be interpreted in a manner that, to the extent
|
| 309 |
+
possible, most closely approximates an absolute disclaimer and
|
| 310 |
+
waiver of all liability.
|
| 311 |
+
|
| 312 |
+
|
| 313 |
+
Section 6 -- Term and Termination.
|
| 314 |
+
|
| 315 |
+
a. This Public License applies for the term of the Copyright and
|
| 316 |
+
Similar Rights licensed here. However, if You fail to comply with
|
| 317 |
+
this Public License, then Your rights under this Public License
|
| 318 |
+
terminate automatically.
|
| 319 |
+
|
| 320 |
+
b. Where Your right to use the Licensed Material has terminated under
|
| 321 |
+
Section 6(a), it reinstates:
|
| 322 |
+
|
| 323 |
+
1. automatically as of the date the violation is cured, provided
|
| 324 |
+
it is cured within 30 days of Your discovery of the
|
| 325 |
+
violation; or
|
| 326 |
+
|
| 327 |
+
2. upon express reinstatement by the Licensor.
|
| 328 |
+
|
| 329 |
+
For the avoidance of doubt, this Section 6(b) does not affect any
|
| 330 |
+
right the Licensor may have to seek remedies for Your violations
|
| 331 |
+
of this Public License.
|
| 332 |
+
|
| 333 |
+
c. For the avoidance of doubt, the Licensor may also offer the
|
| 334 |
+
Licensed Material under separate terms or conditions or stop
|
| 335 |
+
distributing the Licensed Material at any time; however, doing so
|
| 336 |
+
will not terminate this Public License.
|
| 337 |
+
|
| 338 |
+
d. Sections 1, 5, 6, 7, and 8 survive termination of this Public
|
| 339 |
+
License.
|
| 340 |
+
|
| 341 |
+
|
| 342 |
+
Section 7 -- Other Terms and Conditions.
|
| 343 |
+
|
| 344 |
+
a. The Licensor shall not be bound by any additional or different
|
| 345 |
+
terms or conditions communicated by You unless expressly agreed.
|
| 346 |
+
|
| 347 |
+
b. Any arrangements, understandings, or agreements regarding the
|
| 348 |
+
Licensed Material not stated herein are separate from and
|
| 349 |
+
independent of the terms and conditions of this Public License.
|
| 350 |
+
|
| 351 |
+
|
| 352 |
+
Section 8 -- Interpretation.
|
| 353 |
+
|
| 354 |
+
a. For the avoidance of doubt, this Public License does not, and
|
| 355 |
+
shall not be interpreted to, reduce, limit, restrict, or impose
|
| 356 |
+
conditions on any use of the Licensed Material that could lawfully
|
| 357 |
+
be made without permission under this Public License.
|
| 358 |
+
|
| 359 |
+
b. To the extent possible, if any provision of this Public License is
|
| 360 |
+
deemed unenforceable, it shall be automatically reformed to the
|
| 361 |
+
minimum extent necessary to make it enforceable. If the provision
|
| 362 |
+
cannot be reformed, it shall be severed from this Public License
|
| 363 |
+
without affecting the enforceability of the remaining terms and
|
| 364 |
+
conditions.
|
| 365 |
+
|
| 366 |
+
c. No term or condition of this Public License will be waived and no
|
| 367 |
+
failure to comply consented to unless expressly agreed to by the
|
| 368 |
+
Licensor.
|
| 369 |
+
|
| 370 |
+
d. Nothing in this Public License constitutes or may be interpreted
|
| 371 |
+
as a limitation upon, or waiver of, any privileges and immunities
|
| 372 |
+
that apply to the Licensor or You, including from the legal
|
| 373 |
+
processes of any jurisdiction or authority.
|
| 374 |
+
|
| 375 |
+
|
| 376 |
+
=======================================================================
|
| 377 |
+
|
| 378 |
+
Creative Commons is not a party to its public
|
| 379 |
+
licenses. Notwithstanding, Creative Commons may elect to apply one of
|
| 380 |
+
its public licenses to material it publishes and in those instances
|
| 381 |
+
will be considered the “Licensor.” The text of the Creative Commons
|
| 382 |
+
public licenses is dedicated to the public domain under the CC0 Public
|
| 383 |
+
Domain Dedication. Except for the limited purpose of indicating that
|
| 384 |
+
material is shared under a Creative Commons public license or as
|
| 385 |
+
otherwise permitted by the Creative Commons policies published at
|
| 386 |
+
creativecommons.org/policies, Creative Commons does not authorize the
|
| 387 |
+
use of the trademark "Creative Commons" or any other trademark or logo
|
| 388 |
+
of Creative Commons without its prior written consent including,
|
| 389 |
+
without limitation, in connection with any unauthorized modifications
|
| 390 |
+
to any of its public licenses or any other arrangements,
|
| 391 |
+
understandings, or agreements concerning use of licensed material. For
|
| 392 |
+
the avoidance of doubt, this paragraph does not form part of the
|
| 393 |
+
public licenses.
|
| 394 |
+
|
| 395 |
+
Creative Commons may be contacted at creativecommons.org.
|
benchmark/IOAI/IOAI-2025/README.md
ADDED
|
@@ -0,0 +1,108 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
# International Olympiad in Artificial Intelligence (IOAI 2025, Beijing, China)
|
| 2 |
+
|
| 3 |
+
## About IOAI 2025
|
| 4 |
+
|
| 5 |
+
The [**2nd International Olympiad in Artificial Intelligence (IOAI 2025)**](https://ioai-official.org/china-2025/) took place in **Beijing, China**, from **August 2 to 9, 2025**, hosted by **Beijing National Day School (BNDS)** under the patronage of **UNESCO**.
|
| 6 |
+
|
| 7 |
+
- **Contest Rules**: Full rules encompassing the Individual, Team, and GAITE contests are available [here](https://ioai-official.org/china-2025/2025-contest-rules/).
|
| 8 |
+
- **Syllabus**: The official syllabus outlining the AI topics contestants should master is available [here](https://ioai-official.org/china-2025/syllabus-2025/).
|
| 9 |
+
- **Team Challenge**: Details of the “Future Factory” robotics challenge are described [here](https://ioai-official.org/team-challenge/).
|
| 10 |
+
- **Results**: Official medal tables and country results are published [here](https://ioai-official.org/china-2025/results-2025/).
|
| 11 |
+
|
| 12 |
+
## Highlights
|
| 13 |
+
|
| 14 |
+
- **Individual Contest**: A two-day on-site competition preceded by an at-home (practice) round, focused on machine learning, NLP, computer vision, etc.
|
| 15 |
+
- **Team Challenge**: The “Future Factory” robotics-oriented challenge, with a simulated stage and real-robot final using Galbot robots.
|
| 16 |
+
- **GAITE Contest**: A simplified, hint-enabled variant of the Individual Contest, designed for broader accessibility.
|
| 17 |
+
|
| 18 |
+
## Individual Contest Tasks
|
| 19 |
+
|
| 20 |
+
| Task Folder | Task Statement | Reference Solution |
|
| 21 |
+
|-------------|-----------|------------------|
|
| 22 |
+
| [Task 1](Individual-Contest/Radar) | [Radar](Individual-Contest/Radar/Radar.ipynb) | [Solution](Individual-Contest/Radar/Solution/Radar_Solution.ipynb) |
|
| 23 |
+
| [Task 2](Individual-Contest/Chicken_Counting) | [Chicken Counting](Individual-Contest/Chicken_Counting/Chicken_Counting.ipynb) | [Solution](Individual-Contest/Chicken_Counting/Chicken_Counting_Solution.ipynb) |
|
| 24 |
+
| [Task 3](Individual-Contest/Concepts) | [Concepts](Individual-Contest/Concepts/Concepts.ipynb) | [Solution](Individual-Contest/Concepts/Concepts_Solution.ipynb) |
|
| 25 |
+
| [Task 4](Individual-Contest/Restroom) | [Restroom Icon Matching](Individual-Contest/Restroom/Restroom.ipynb) | [Solution](Individual-Contest/Restroom/Solution/Restroom_Solution.ipynb) |
|
| 26 |
+
| [Task 5](Individual-Contest/Antique) | [Antique Painting Authentication](Individual-Contest/Antique/Antique.ipynb) | [Solution](Individual-Contest/Antique/Solution/Antique_Solution.ipynb) |
|
| 27 |
+
| [Task 6](Individual-Contest/Pixel) | [Pixel Efficiency](Individual-Contest/Pixel/Pixel.ipynb) | [Solution](Individual-Contest/Pixel/Pixel_Solution.ipynb) |
|
| 28 |
+
|
| 29 |
+
|
| 30 |
+
## Environment Setup
|
| 31 |
+
|
| 32 |
+
The competition environment uses Python 3.12.7 and includes a comprehensive set of dependencies listed in [requirements.txt](requirements.txt). The contestants were not allowed to install other external libraries, so these were the only packages they could use. Below are instructions for setting up the environment using different package managers.
|
| 33 |
+
|
| 34 |
+
### Using Conda (Recommended)
|
| 35 |
+
|
| 36 |
+
```bash
|
| 37 |
+
# Create and activate a new conda environment
|
| 38 |
+
conda create -n ioai-2025 python=3.12.7
|
| 39 |
+
conda activate ioai-2025
|
| 40 |
+
|
| 41 |
+
# Update pip and install dependencies
|
| 42 |
+
pip install --upgrade pip
|
| 43 |
+
pip install --no-deps -r requirements.txt
|
| 44 |
+
```
|
| 45 |
+
|
| 46 |
+
### Using venv
|
| 47 |
+
|
| 48 |
+
```bash
|
| 49 |
+
# Linux/macOS
|
| 50 |
+
python3.12 -m venv ioai-2025
|
| 51 |
+
source ioai-2025/bin/activate
|
| 52 |
+
|
| 53 |
+
# Windows
|
| 54 |
+
python -m venv ioai-2025
|
| 55 |
+
.\ioai-2025\Scripts\activate
|
| 56 |
+
|
| 57 |
+
# Install dependencies (all platforms)
|
| 58 |
+
pip install --upgrade pip
|
| 59 |
+
pip install --no-deps -r requirements.txt
|
| 60 |
+
```
|
| 61 |
+
|
| 62 |
+
### Using pyenv
|
| 63 |
+
|
| 64 |
+
```bash
|
| 65 |
+
# Install Python 3.12.7
|
| 66 |
+
pyenv install 3.12.7
|
| 67 |
+
pyenv local 3.12.7
|
| 68 |
+
|
| 69 |
+
# Create and activate virtual environment
|
| 70 |
+
python -m venv .venv
|
| 71 |
+
source .venv/bin/activate # Linux/macOS
|
| 72 |
+
.\.venv\Scripts\activate # Windows
|
| 73 |
+
|
| 74 |
+
# Install dependencies
|
| 75 |
+
pip install --upgrade pip
|
| 76 |
+
pip install --no-deps -r requirements.txt
|
| 77 |
+
```
|
| 78 |
+
|
| 79 |
+
> **Note**: The `--no-deps` flag is required to ensure exact package versions match the competition environment.
|
| 80 |
+
|
| 81 |
+
## Translations of Individual Contest Tasks
|
| 82 |
+
|
| 83 |
+
Translated versions of the Individual Contest task statements are available for [Day 1](Translations/Individual-Contest-Day1) and [Day 2](Translations/Individual-Contest-Day2).
|
| 84 |
+
|
| 85 |
+
These translations were optionally prepared by Team Leaders and provided to their contestants during the contest, alongside the official English version.
|
| 86 |
+
|
| 87 |
+
## Task Authors & Contributors
|
| 88 |
+
|
| 89 |
+
### Individual Contest
|
| 90 |
+
- **Task 1 – Radar**: Team from **Peking University**
|
| 91 |
+
- **Task 2 – Satellite Weather Forecasting & Chicken Counting**: **Evgenii Tsymbalov (At-Home)** & Team from **Shenzhen University (On-Site)**
|
| 92 |
+
- **Task 3 – Concepts**: **Alham Aji**
|
| 93 |
+
- **Task 4 – Restroom Icon Matching**: Team from **Beihang University**
|
| 94 |
+
- **Task 5 – Antique Painting Authentication**: **Dong Yixi**, DP Technology
|
| 95 |
+
- **Task 6 – Pixel Efficiency Challenge**: **Kirill Fedyanin**
|
| 96 |
+
|
| 97 |
+
### GAITE Contest
|
| 98 |
+
- **Task 3 – Resonance Elf**: **Ma Chichuan**, Beijing Navigation School
|
| 99 |
+
- **Task 4 – Combinatorial Word Segmentation**: **Li Yulin**, Microsoft
|
| 100 |
+
- **Task 5 – Synthetic Speech Detector**: **Li Yulin**, Microsoft
|
| 101 |
+
|
| 102 |
+
### Team Challenge
|
| 103 |
+
- **Factory of the Future**: Team from **Galbot** and **Beijing National Day School**
|
| 104 |
+
|
| 105 |
+
## License
|
| 106 |
+
|
| 107 |
+
This work is released under the **Creative Commons Attribution 4.0 International (CC-BY-4.0)** License.
|
| 108 |
+
You may share and adapt this content as long as proper credit is given and changes are clearly indicated.
|
benchmark/IOAI/IOAI-2025/requirements.txt
ADDED
|
@@ -0,0 +1,521 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
absl-py==2.3.1
|
| 2 |
+
accelerate==1.8.1
|
| 3 |
+
aiobotocore==2.19.0
|
| 4 |
+
aiohappyeyeballs==2.4.4
|
| 5 |
+
aiohttp==3.11.10
|
| 6 |
+
aioitertools==0.7.1
|
| 7 |
+
aiosignal==1.2.0
|
| 8 |
+
airportsdata==20250706
|
| 9 |
+
alabaster==0.7.16
|
| 10 |
+
alembic==1.15.2
|
| 11 |
+
altair==5.5.0
|
| 12 |
+
annotated-types==0.6.0
|
| 13 |
+
anthropic==0.60.0
|
| 14 |
+
anyio==4.7.0
|
| 15 |
+
appdirs==1.4.4
|
| 16 |
+
archspec==0.2.3
|
| 17 |
+
argon2-cffi==21.3.0
|
| 18 |
+
argon2-cffi-bindings==21.2.0
|
| 19 |
+
arrow==1.3.0
|
| 20 |
+
astor==0.8.1
|
| 21 |
+
astroid==3.3.8
|
| 22 |
+
astropy==7.0.0
|
| 23 |
+
astropy-iers-data==0.2025.1.13.0.34.51
|
| 24 |
+
asttokens==3.0.0
|
| 25 |
+
async-lru==2.0.4
|
| 26 |
+
asyncssh==2.17.0
|
| 27 |
+
atomicwrites==1.4.0
|
| 28 |
+
attrs==24.3.0
|
| 29 |
+
audioread==3.0.1
|
| 30 |
+
Automat==24.8.1
|
| 31 |
+
autopep8==2.0.4
|
| 32 |
+
autoviz==0.1.905
|
| 33 |
+
babel==2.16.0
|
| 34 |
+
banal==1.0.6
|
| 35 |
+
bcrypt==3.2.0
|
| 36 |
+
beautifulsoup4==4.12.3
|
| 37 |
+
binaryornot==0.4.4
|
| 38 |
+
bitsandbytes==0.46.1
|
| 39 |
+
black==24.10.0
|
| 40 |
+
blake3==1.0.5
|
| 41 |
+
bleach==6.2.0
|
| 42 |
+
blinker==1.9.0
|
| 43 |
+
blis==1.3.0
|
| 44 |
+
blobfile==3.0.0
|
| 45 |
+
bokeh==3.6.2
|
| 46 |
+
boltons==24.1.0
|
| 47 |
+
botocore==1.36.3
|
| 48 |
+
Bottleneck==1.4.2
|
| 49 |
+
Brotli==1.0.9
|
| 50 |
+
brotlipy==0.7.0
|
| 51 |
+
build==1.2.2.post1
|
| 52 |
+
cached-property==1.5.2
|
| 53 |
+
cachetools==5.5.1
|
| 54 |
+
catalogue==2.0.10
|
| 55 |
+
catboost==1.2.8
|
| 56 |
+
cbor2==5.6.5
|
| 57 |
+
certifi==2025.7.14
|
| 58 |
+
cffi==1.17.1
|
| 59 |
+
chardet==4.0.0
|
| 60 |
+
charset-normalizer==3.3.2
|
| 61 |
+
click==8.1.8
|
| 62 |
+
cloudpathlib==0.21.1
|
| 63 |
+
cloudpickle==3.0.0
|
| 64 |
+
colorama==0.4.6
|
| 65 |
+
colorcet==3.1.0
|
| 66 |
+
comm==0.2.1
|
| 67 |
+
compressed-tensors==0.10.2
|
| 68 |
+
confection==0.1.5
|
| 69 |
+
constantly==23.10.4
|
| 70 |
+
contourpy==1.3.1
|
| 71 |
+
cookiecutter==2.6.0
|
| 72 |
+
cryptography==44.0.1
|
| 73 |
+
cssselect==1.2.0
|
| 74 |
+
cuda-bindings==12.9.0
|
| 75 |
+
cuda-python==12.9.0
|
| 76 |
+
cupy-cuda12x==13.5.1
|
| 77 |
+
cut-cross-entropy==25.1.1
|
| 78 |
+
cycler==0.11.0
|
| 79 |
+
cymem==2.0.11
|
| 80 |
+
cytoolz==1.0.1
|
| 81 |
+
dask==2025.2.0
|
| 82 |
+
dask-expr==2.0.0
|
| 83 |
+
dataset==1.6.2
|
| 84 |
+
datasets==3.6.0
|
| 85 |
+
datashader==0.18.0
|
| 86 |
+
debugpy==1.8.11
|
| 87 |
+
decorator==5.1.1
|
| 88 |
+
decord==0.6.0
|
| 89 |
+
defusedxml==0.7.1
|
| 90 |
+
Deprecated==1.2.13
|
| 91 |
+
depyf==0.19.0
|
| 92 |
+
diff-match-patch==20200713
|
| 93 |
+
diffusers==0.34.0
|
| 94 |
+
dill==0.3.8
|
| 95 |
+
diskcache==5.6.3
|
| 96 |
+
distributed==2025.2.0
|
| 97 |
+
distro==1.9.0
|
| 98 |
+
dnspython==2.7.0
|
| 99 |
+
docstring_parser==0.17.0
|
| 100 |
+
docstring-to-markdown==0.11
|
| 101 |
+
docutils==0.21.2
|
| 102 |
+
einops==0.8.1
|
| 103 |
+
email_validator==2.2.0
|
| 104 |
+
emoji==2.14.1
|
| 105 |
+
et-xmlfile==1.1.0
|
| 106 |
+
evalidate==2.0.3
|
| 107 |
+
evaluate==0.4.4
|
| 108 |
+
executing==0.8.3
|
| 109 |
+
fastapi==0.116.1
|
| 110 |
+
fastapi-cli==0.0.8
|
| 111 |
+
fastapi-cloud-cli==0.1.5
|
| 112 |
+
fastjsonschema==2.20.0
|
| 113 |
+
fastrlock==0.8.3
|
| 114 |
+
fasttext==0.9.3
|
| 115 |
+
filelock==3.17.0
|
| 116 |
+
flake8==7.1.1
|
| 117 |
+
flashinfer-python==0.2.9rc2
|
| 118 |
+
Flask==3.1.0
|
| 119 |
+
fonttools==4.55.3
|
| 120 |
+
frozendict==2.4.2
|
| 121 |
+
frozenlist==1.5.0
|
| 122 |
+
fsspec==2024.12.0
|
| 123 |
+
ftfy==6.3.1
|
| 124 |
+
gensim==4.3.3
|
| 125 |
+
gguf==0.17.1
|
| 126 |
+
gitdb==4.0.7
|
| 127 |
+
GitPython==3.1.43
|
| 128 |
+
gmpy2==2.2.1
|
| 129 |
+
graphviz==0.21
|
| 130 |
+
greenlet==3.1.1
|
| 131 |
+
grpcio==1.73.1
|
| 132 |
+
h11==0.14.0
|
| 133 |
+
h5py==3.12.1
|
| 134 |
+
HeapDict==1.0.1
|
| 135 |
+
hf_transfer==0.1.9
|
| 136 |
+
hf-xet==1.1.5
|
| 137 |
+
holoviews==1.20.2
|
| 138 |
+
httpcore==1.0.2
|
| 139 |
+
httptools==0.6.4
|
| 140 |
+
httpx==0.27.0
|
| 141 |
+
huggingface-hub==0.34.2
|
| 142 |
+
hvplot==0.11.2
|
| 143 |
+
hyperlink==21.0.0
|
| 144 |
+
idna==3.7
|
| 145 |
+
imagecodecs==2024.9.22
|
| 146 |
+
imageio==2.37.0
|
| 147 |
+
imagesize==1.4.1
|
| 148 |
+
imbalanced-learn==0.13.0
|
| 149 |
+
importlib_metadata==8.5.0
|
| 150 |
+
incremental==24.7.2
|
| 151 |
+
inflection==0.5.1
|
| 152 |
+
iniconfig==1.1.1
|
| 153 |
+
intake==2.0.7
|
| 154 |
+
interegular==0.3.3
|
| 155 |
+
intervaltree==3.1.0
|
| 156 |
+
ipykernel==6.29.5
|
| 157 |
+
ipython==8.30.0
|
| 158 |
+
ipython-genutils==0.2.0
|
| 159 |
+
ipython_pygments_lexers==1.1.1
|
| 160 |
+
ipywidgets==7.8.5
|
| 161 |
+
isort==6.0.1
|
| 162 |
+
itemadapter==0.3.0
|
| 163 |
+
itemloaders==1.3.2
|
| 164 |
+
itsdangerous==2.2.0
|
| 165 |
+
jedi==0.19.2
|
| 166 |
+
jeepney==0.7.1
|
| 167 |
+
jellyfish==1.1.3
|
| 168 |
+
Jinja2==3.1.6
|
| 169 |
+
jiter==0.10.0
|
| 170 |
+
jmespath==1.0.1
|
| 171 |
+
joblib==1.4.2
|
| 172 |
+
json5==0.9.25
|
| 173 |
+
jsonpatch==1.33
|
| 174 |
+
jsonpointer==2.1
|
| 175 |
+
jsonschema==4.23.0
|
| 176 |
+
jsonschema-specifications==2023.7.1
|
| 177 |
+
jupyter==1.1.1
|
| 178 |
+
jupyter_client==8.6.3
|
| 179 |
+
jupyter-console==6.6.3
|
| 180 |
+
jupyter_core==5.7.2
|
| 181 |
+
jupyter-events==0.12.0
|
| 182 |
+
jupyter-lsp==2.2.5
|
| 183 |
+
jupyter_server==2.15.0
|
| 184 |
+
jupyter_server_terminals==0.5.3
|
| 185 |
+
jupyterlab==4.3.4
|
| 186 |
+
jupyterlab_pygments==0.3.0
|
| 187 |
+
jupyterlab_server==2.27.3
|
| 188 |
+
jupyterlab-widgets==1.0.0
|
| 189 |
+
keyring==25.6.0
|
| 190 |
+
kiwisolver==1.4.8
|
| 191 |
+
langcodes==3.5.0
|
| 192 |
+
language_data==1.3.0
|
| 193 |
+
lark==1.2.2
|
| 194 |
+
lazy_loader==0.4
|
| 195 |
+
lazy-object-proxy==1.10.0
|
| 196 |
+
lckr_jupyterlab_variableinspector==3.2.4
|
| 197 |
+
libarchive-c==5.1
|
| 198 |
+
librosa==0.11.0
|
| 199 |
+
lightgbm==4.6.0
|
| 200 |
+
lightning-utilities==0.14.3
|
| 201 |
+
linkify-it-py==2.0.0
|
| 202 |
+
litellm==1.74.9.post1
|
| 203 |
+
llguidance==0.7.30
|
| 204 |
+
llvmlite==0.44.0
|
| 205 |
+
lm-format-enforcer==0.10.11
|
| 206 |
+
lmdb==1.6.2
|
| 207 |
+
locket==1.0.0
|
| 208 |
+
lxml==5.3.0
|
| 209 |
+
lz4==4.3.3
|
| 210 |
+
Mako==1.2.3
|
| 211 |
+
marisa-trie==1.2.1
|
| 212 |
+
Markdown==3.8
|
| 213 |
+
markdown-it-py==2.2.0
|
| 214 |
+
MarkupSafe==3.0.2
|
| 215 |
+
matplotlib==3.10.0
|
| 216 |
+
matplotlib-inline==0.1.6
|
| 217 |
+
mccabe==0.7.0
|
| 218 |
+
mdit-py-plugins==0.3.0
|
| 219 |
+
mdurl==0.1.0
|
| 220 |
+
mistral_common==1.8.3
|
| 221 |
+
mistune==3.1.2
|
| 222 |
+
mkl_fft==1.3.11
|
| 223 |
+
mkl_random==1.2.8
|
| 224 |
+
modelscope==1.28.1
|
| 225 |
+
more-itertools==10.3.0
|
| 226 |
+
mpmath==1.3.0
|
| 227 |
+
msgpack==1.0.3
|
| 228 |
+
msgspec==0.19.0
|
| 229 |
+
multidict==6.1.0
|
| 230 |
+
multipledispatch==0.6.0
|
| 231 |
+
multiprocess==0.70.16
|
| 232 |
+
murmurhash==1.0.13
|
| 233 |
+
mypy==1.14.1
|
| 234 |
+
mypy-extensions==1.0.0
|
| 235 |
+
narwhals==1.31.0
|
| 236 |
+
nest-asyncio==1.6.0
|
| 237 |
+
networkx==3.4.2
|
| 238 |
+
ninja==1.11.1.4
|
| 239 |
+
nltk==3.9.1
|
| 240 |
+
notebook==7.3.2
|
| 241 |
+
notebook_shim==0.2.4
|
| 242 |
+
numba==0.61.2
|
| 243 |
+
numexpr==2.10.1
|
| 244 |
+
numpy==2.2.6
|
| 245 |
+
numpydoc==1.7.0
|
| 246 |
+
nvidia-cublas-cu12==12.6.4.1
|
| 247 |
+
nvidia-cuda-cupti-cu12==12.6.80
|
| 248 |
+
nvidia-cuda-nvrtc-cu12==12.6.77
|
| 249 |
+
nvidia-cuda-runtime-cu12==12.6.77
|
| 250 |
+
nvidia-cudnn-cu12==9.5.1.17
|
| 251 |
+
nvidia-cudnn-frontend==1.13.0
|
| 252 |
+
nvidia-cufft-cu12==11.3.0.4
|
| 253 |
+
nvidia-cufile-cu12==1.11.1.6
|
| 254 |
+
nvidia-curand-cu12==10.3.7.77
|
| 255 |
+
nvidia-cusolver-cu12==11.7.1.2
|
| 256 |
+
nvidia-cusparse-cu12==12.5.4.2
|
| 257 |
+
nvidia-cusparselt-cu12==0.6.3
|
| 258 |
+
nvidia-ml-py==12.575.51
|
| 259 |
+
nvidia-nccl-cu12==2.26.2
|
| 260 |
+
nvidia-nvjitlink-cu12==12.6.85
|
| 261 |
+
nvidia-nvshmem-cu12==3.3.9
|
| 262 |
+
nvidia-nvtx-cu12==12.6.77
|
| 263 |
+
openai==1.90.0
|
| 264 |
+
opencv-python==4.11.0.86
|
| 265 |
+
opencv-python-headless==4.12.0.88
|
| 266 |
+
openpyxl==3.1.5
|
| 267 |
+
orjson==3.11.1
|
| 268 |
+
outlines==0.1.11
|
| 269 |
+
outlines_core==0.1.26
|
| 270 |
+
overrides==7.4.0
|
| 271 |
+
packaging==24.2
|
| 272 |
+
pandas==2.2.3
|
| 273 |
+
pandas-dq==1.29
|
| 274 |
+
pandocfilters==1.5.0
|
| 275 |
+
panel==1.6.3
|
| 276 |
+
param==2.2.0
|
| 277 |
+
paramiko==3.5.0
|
| 278 |
+
parsel==1.8.1
|
| 279 |
+
parso==0.8.4
|
| 280 |
+
partd==1.4.2
|
| 281 |
+
partial-json-parser==0.2.1.1.post6
|
| 282 |
+
pathspec==0.10.3
|
| 283 |
+
patsy==1.0.1
|
| 284 |
+
peft==0.16.0
|
| 285 |
+
pexpect==4.8.0
|
| 286 |
+
pickleshare==0.7.5
|
| 287 |
+
pillow==11.1.0
|
| 288 |
+
pip==25.1
|
| 289 |
+
pkce==1.0.3
|
| 290 |
+
pkginfo==1.12.0
|
| 291 |
+
platformdirs==4.3.7
|
| 292 |
+
plotly==6.0.1
|
| 293 |
+
pluggy==1.5.0
|
| 294 |
+
ply==3.11
|
| 295 |
+
pooch==1.8.2
|
| 296 |
+
preshed==3.0.10
|
| 297 |
+
prometheus_client==0.21.1
|
| 298 |
+
prometheus-fastapi-instrumentator==7.1.0
|
| 299 |
+
prompt-toolkit==3.0.43
|
| 300 |
+
propcache==0.3.1
|
| 301 |
+
Protego==0.1.16
|
| 302 |
+
protobuf==5.28.3
|
| 303 |
+
psutil==5.9.0
|
| 304 |
+
ptyprocess==0.7.0
|
| 305 |
+
pure-eval==0.2.2
|
| 306 |
+
py-cpuinfo==9.0.0
|
| 307 |
+
pyamg==5.2.1
|
| 308 |
+
pyarrow==19.0.0
|
| 309 |
+
pyasn1==0.4.8
|
| 310 |
+
pyasn1-modules==0.2.8
|
| 311 |
+
pybase64==1.4.2
|
| 312 |
+
pybind11==2.13.6
|
| 313 |
+
pycodestyle==2.12.1
|
| 314 |
+
pycosat==0.6.6
|
| 315 |
+
pycountry==24.6.1
|
| 316 |
+
pycparser==2.21
|
| 317 |
+
pycryptodomex==3.23.0
|
| 318 |
+
pyct==0.5.0
|
| 319 |
+
pycurl==7.45.6
|
| 320 |
+
pydantic==2.10.3
|
| 321 |
+
pydantic_core==2.27.1
|
| 322 |
+
pydantic-extra-types==2.10.5
|
| 323 |
+
pydantic-settings==2.6.1
|
| 324 |
+
pydeck==0.9.1
|
| 325 |
+
PyDispatcher==2.0.5
|
| 326 |
+
pydocstyle==6.3.0
|
| 327 |
+
pyerfa==2.0.1.5
|
| 328 |
+
pyflakes==3.2.0
|
| 329 |
+
PyGithub==2.4.0
|
| 330 |
+
Pygments==2.19.1
|
| 331 |
+
PyJWT==2.10.1
|
| 332 |
+
pylint==3.3.5
|
| 333 |
+
pylint-venv==3.0.3
|
| 334 |
+
pyls-spyder==0.4.0
|
| 335 |
+
PyNaCl==1.5.0
|
| 336 |
+
pynvml==12.0.0
|
| 337 |
+
pyodbc==5.2.0
|
| 338 |
+
pyOpenSSL==25.0.0
|
| 339 |
+
pyparsing==3.2.0
|
| 340 |
+
pyproject_hooks==1.2.0
|
| 341 |
+
PyQt5==5.15.10
|
| 342 |
+
PyQt5_sip==12.13.0
|
| 343 |
+
PyQtWebEngine==5.15.6
|
| 344 |
+
PySocks==1.7.1
|
| 345 |
+
pytest==8.3.4
|
| 346 |
+
python-dateutil==2.9.0.post0
|
| 347 |
+
python-dotenv==1.1.0
|
| 348 |
+
python-json-logger==3.2.1
|
| 349 |
+
python-lsp-black==2.0.0
|
| 350 |
+
python-lsp-jsonrpc==1.1.2
|
| 351 |
+
python-lsp-server==1.12.2
|
| 352 |
+
python-multipart==0.0.20
|
| 353 |
+
python-slugify==5.0.2
|
| 354 |
+
pythonping==1.1.4
|
| 355 |
+
pytoolconfig==1.2.6
|
| 356 |
+
pytorch-lightning==2.5.2
|
| 357 |
+
pytz==2024.1
|
| 358 |
+
pyuca==1.2
|
| 359 |
+
pyviz_comms==3.0.2
|
| 360 |
+
PyWavelets==1.8.0
|
| 361 |
+
pyxdg==0.27
|
| 362 |
+
PyYAML==6.0.2
|
| 363 |
+
pyzmq==26.2.0
|
| 364 |
+
QDarkStyle==3.2.3
|
| 365 |
+
qstylizer==0.2.2
|
| 366 |
+
QtAwesome==1.4.0
|
| 367 |
+
qtconsole==5.6.1
|
| 368 |
+
QtPy==2.4.1
|
| 369 |
+
queuelib==1.6.2
|
| 370 |
+
ray==2.48.0
|
| 371 |
+
readchar==4.0.5
|
| 372 |
+
referencing==0.30.2
|
| 373 |
+
regex==2024.11.6
|
| 374 |
+
requests==2.32.3
|
| 375 |
+
requests-file==1.5.1
|
| 376 |
+
requests-toolbelt==1.0.0
|
| 377 |
+
rfc3339-validator==0.1.4
|
| 378 |
+
rfc3986-validator==0.1.1
|
| 379 |
+
rich==13.9.4
|
| 380 |
+
rich-toolkit==0.14.9
|
| 381 |
+
rignore==0.6.4
|
| 382 |
+
roman-numerals-py==3.1.0
|
| 383 |
+
rope==1.13.0
|
| 384 |
+
rpds-py==0.22.3
|
| 385 |
+
Rtree==1.0.1
|
| 386 |
+
ruamel.yaml==0.18.10
|
| 387 |
+
ruamel.yaml.clib==0.2.12
|
| 388 |
+
s3fs==2024.12.0
|
| 389 |
+
safetensors==0.5.3
|
| 390 |
+
scikit-image==0.25.0
|
| 391 |
+
scikit-learn==1.6.1
|
| 392 |
+
scipy==1.13.1
|
| 393 |
+
Scrapy==2.12.0
|
| 394 |
+
seaborn==0.13.2
|
| 395 |
+
SecretStorage==3.3.1
|
| 396 |
+
semver==3.0.2
|
| 397 |
+
Send2Trash==1.8.2
|
| 398 |
+
sentence-transformers==4.1.0
|
| 399 |
+
sentencepiece==0.2.0
|
| 400 |
+
sentry-sdk==2.33.2
|
| 401 |
+
service-identity==18.1.0
|
| 402 |
+
setproctitle==1.3.6
|
| 403 |
+
setuptools==78.1.1
|
| 404 |
+
sgl-kernel==0.2.7
|
| 405 |
+
sglang==0.4.9.post5
|
| 406 |
+
shellingham==1.5.0
|
| 407 |
+
shtab==1.7.2
|
| 408 |
+
sip==6.7.12
|
| 409 |
+
six==1.17.0
|
| 410 |
+
sklearn-compat==0.1.3
|
| 411 |
+
smart-open==5.2.1
|
| 412 |
+
smmap==4.0.0
|
| 413 |
+
sniffio==1.3.0
|
| 414 |
+
snowballstemmer==2.2.0
|
| 415 |
+
sortedcontainers==2.4.0
|
| 416 |
+
soundfile==0.13.1
|
| 417 |
+
soupsieve==2.5
|
| 418 |
+
soxr==0.5.0.post1
|
| 419 |
+
spacy==3.8.7
|
| 420 |
+
spacy-legacy==3.0.12
|
| 421 |
+
spacy-loggers==1.0.5
|
| 422 |
+
Sphinx==8.2.3
|
| 423 |
+
sphinxcontrib-applehelp==2.0.0
|
| 424 |
+
sphinxcontrib-devhelp==2.0.0
|
| 425 |
+
sphinxcontrib-htmlhelp==2.1.0
|
| 426 |
+
sphinxcontrib-jsmath==1.0.1
|
| 427 |
+
sphinxcontrib-qthelp==2.0.0
|
| 428 |
+
sphinxcontrib-serializinghtml==2.0.0
|
| 429 |
+
spyder==6.0.5
|
| 430 |
+
spyder-kernels==3.0.3
|
| 431 |
+
SQLAlchemy==1.4.54
|
| 432 |
+
srsly==2.5.1
|
| 433 |
+
stack-data==0.2.0
|
| 434 |
+
starlette==0.47.2
|
| 435 |
+
statsmodels==0.14.4
|
| 436 |
+
streamlit==1.44.1
|
| 437 |
+
superqt==0.7.3
|
| 438 |
+
sympy==1.13.3
|
| 439 |
+
tabulate==0.9.0
|
| 440 |
+
tblib==1.7.0
|
| 441 |
+
tenacity==9.0.0
|
| 442 |
+
tensorboard==2.19.0
|
| 443 |
+
tensorboard-data-server==0.7.2
|
| 444 |
+
terminado==0.17.1
|
| 445 |
+
text-unidecode==1.3
|
| 446 |
+
textblob==0.19.0
|
| 447 |
+
textdistance==4.6.3
|
| 448 |
+
thinc==8.3.6
|
| 449 |
+
threadpoolctl==3.5.0
|
| 450 |
+
three-merge==0.1.1
|
| 451 |
+
tifffile==2024.12.12
|
| 452 |
+
tiktoken==0.9.0
|
| 453 |
+
timm==1.0.16
|
| 454 |
+
tinycss2==1.4.0
|
| 455 |
+
tldextract==5.1.2
|
| 456 |
+
tokenizers==0.21.2
|
| 457 |
+
toml==0.10.2
|
| 458 |
+
tomli==2.0.1
|
| 459 |
+
tomlkit==0.13.2
|
| 460 |
+
toolz==1.0.0
|
| 461 |
+
torch==2.7.1
|
| 462 |
+
torch_memory_saver==0.0.8
|
| 463 |
+
torchao==0.9.0
|
| 464 |
+
torchaudio==2.7.1
|
| 465 |
+
torchmetrics==1.7.3
|
| 466 |
+
torchvision==0.22.1
|
| 467 |
+
tornado==6.4.2
|
| 468 |
+
tqdm==4.67.1
|
| 469 |
+
traitlets==5.14.3
|
| 470 |
+
transformers==4.54.0
|
| 471 |
+
triton==3.3.1
|
| 472 |
+
trl==0.19.1
|
| 473 |
+
truststore==0.10.0
|
| 474 |
+
Twisted==24.11.0
|
| 475 |
+
typeguard==4.4.4
|
| 476 |
+
typer==0.16.0
|
| 477 |
+
typing_extensions==4.14.1
|
| 478 |
+
tyro==0.9.26
|
| 479 |
+
tzdata==2025.2
|
| 480 |
+
uc-micro-py==1.0.1
|
| 481 |
+
ujson==5.10.0
|
| 482 |
+
unicodedata2==15.1.0
|
| 483 |
+
Unidecode==1.3.8
|
| 484 |
+
unsloth==2025.7.8
|
| 485 |
+
unsloth_zoo==2025.7.10
|
| 486 |
+
urllib3==2.3.0
|
| 487 |
+
utils==1.0.2
|
| 488 |
+
uvicorn==0.35.0
|
| 489 |
+
uvloop==0.21.0
|
| 490 |
+
vllm==0.10.0
|
| 491 |
+
w3lib==2.1.2
|
| 492 |
+
wasabi==1.1.3
|
| 493 |
+
watchdog==4.0.2
|
| 494 |
+
watchfiles==1.1.0
|
| 495 |
+
wcwidth==0.2.5
|
| 496 |
+
weasel==0.4.1
|
| 497 |
+
webencodings==0.5.1
|
| 498 |
+
websocket-client==1.8.0
|
| 499 |
+
websockets==15.0.1
|
| 500 |
+
Werkzeug==3.1.3
|
| 501 |
+
whatthepatch==1.0.2
|
| 502 |
+
wheel==0.45.1
|
| 503 |
+
widgetsnbextension==3.6.10
|
| 504 |
+
wordcloud==1.9.4
|
| 505 |
+
wrapt==1.17.0
|
| 506 |
+
wurlitzer==3.0.2
|
| 507 |
+
xarray==2024.11.0
|
| 508 |
+
xformers==0.0.31
|
| 509 |
+
xgboost==3.0.2
|
| 510 |
+
xgrammar==0.1.21
|
| 511 |
+
xlrd==2.0.2
|
| 512 |
+
xlwings==0.32.1
|
| 513 |
+
xxhash==3.5.0
|
| 514 |
+
xyzservices==2022.9.0
|
| 515 |
+
yapf==0.40.2
|
| 516 |
+
yarl==1.18.0
|
| 517 |
+
zict==3.0.0
|
| 518 |
+
zipp==3.21.0
|
| 519 |
+
zope.interface==7.1.1
|
| 520 |
+
zstandard==0.23.0
|
| 521 |
+
git+https://github.com/openai/CLIP.git
|
benchmark/IOAI/IOAI2025/.gitattributes
ADDED
|
@@ -0,0 +1,220 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
*.7z filter=lfs diff=lfs merge=lfs -text
|
| 2 |
+
*.arrow filter=lfs diff=lfs merge=lfs -text
|
| 3 |
+
*.bin filter=lfs diff=lfs merge=lfs -text
|
| 4 |
+
*.bz2 filter=lfs diff=lfs merge=lfs -text
|
| 5 |
+
*.ckpt filter=lfs diff=lfs merge=lfs -text
|
| 6 |
+
*.ftz filter=lfs diff=lfs merge=lfs -text
|
| 7 |
+
*.gz filter=lfs diff=lfs merge=lfs -text
|
| 8 |
+
*.h5 filter=lfs diff=lfs merge=lfs -text
|
| 9 |
+
*.joblib filter=lfs diff=lfs merge=lfs -text
|
| 10 |
+
*.lfs.* filter=lfs diff=lfs merge=lfs -text
|
| 11 |
+
*.lz4 filter=lfs diff=lfs merge=lfs -text
|
| 12 |
+
*.mds filter=lfs diff=lfs merge=lfs -text
|
| 13 |
+
*.mlmodel filter=lfs diff=lfs merge=lfs -text
|
| 14 |
+
*.model filter=lfs diff=lfs merge=lfs -text
|
| 15 |
+
*.msgpack filter=lfs diff=lfs merge=lfs -text
|
| 16 |
+
*.npy filter=lfs diff=lfs merge=lfs -text
|
| 17 |
+
*.npz filter=lfs diff=lfs merge=lfs -text
|
| 18 |
+
*.onnx filter=lfs diff=lfs merge=lfs -text
|
| 19 |
+
*.ot filter=lfs diff=lfs merge=lfs -text
|
| 20 |
+
*.parquet filter=lfs diff=lfs merge=lfs -text
|
| 21 |
+
*.pb filter=lfs diff=lfs merge=lfs -text
|
| 22 |
+
*.pickle filter=lfs diff=lfs merge=lfs -text
|
| 23 |
+
*.pkl filter=lfs diff=lfs merge=lfs -text
|
| 24 |
+
*.pt filter=lfs diff=lfs merge=lfs -text
|
| 25 |
+
*.pth filter=lfs diff=lfs merge=lfs -text
|
| 26 |
+
*.rar filter=lfs diff=lfs merge=lfs -text
|
| 27 |
+
*.safetensors filter=lfs diff=lfs merge=lfs -text
|
| 28 |
+
saved_model/**/* filter=lfs diff=lfs merge=lfs -text
|
| 29 |
+
*.tar.* filter=lfs diff=lfs merge=lfs -text
|
| 30 |
+
*.tar filter=lfs diff=lfs merge=lfs -text
|
| 31 |
+
*.tflite filter=lfs diff=lfs merge=lfs -text
|
| 32 |
+
*.tgz filter=lfs diff=lfs merge=lfs -text
|
| 33 |
+
*.wasm filter=lfs diff=lfs merge=lfs -text
|
| 34 |
+
*.xz filter=lfs diff=lfs merge=lfs -text
|
| 35 |
+
*.zip filter=lfs diff=lfs merge=lfs -text
|
| 36 |
+
*.zst filter=lfs diff=lfs merge=lfs -text
|
| 37 |
+
*tfevents* filter=lfs diff=lfs merge=lfs -text
|
| 38 |
+
# Audio files - uncompressed
|
| 39 |
+
*.pcm filter=lfs diff=lfs merge=lfs -text
|
| 40 |
+
*.sam filter=lfs diff=lfs merge=lfs -text
|
| 41 |
+
*.raw filter=lfs diff=lfs merge=lfs -text
|
| 42 |
+
# Audio files - compressed
|
| 43 |
+
*.aac filter=lfs diff=lfs merge=lfs -text
|
| 44 |
+
*.flac filter=lfs diff=lfs merge=lfs -text
|
| 45 |
+
*.mp3 filter=lfs diff=lfs merge=lfs -text
|
| 46 |
+
*.ogg filter=lfs diff=lfs merge=lfs -text
|
| 47 |
+
*.wav filter=lfs diff=lfs merge=lfs -text
|
| 48 |
+
# Image files - uncompressed
|
| 49 |
+
*.bmp filter=lfs diff=lfs merge=lfs -text
|
| 50 |
+
*.gif filter=lfs diff=lfs merge=lfs -text
|
| 51 |
+
*.png filter=lfs diff=lfs merge=lfs -text
|
| 52 |
+
*.tiff filter=lfs diff=lfs merge=lfs -text
|
| 53 |
+
# Image files - compressed
|
| 54 |
+
*.jpg filter=lfs diff=lfs merge=lfs -text
|
| 55 |
+
*.jpeg filter=lfs diff=lfs merge=lfs -text
|
| 56 |
+
*.webp filter=lfs diff=lfs merge=lfs -text
|
| 57 |
+
# Video files - compressed
|
| 58 |
+
*.mp4 filter=lfs diff=lfs merge=lfs -text
|
| 59 |
+
*.webm filter=lfs diff=lfs merge=lfs -text
|
| 60 |
+
Translations/Individual-Contest-Day1/Albania/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Albania.docx filter=lfs diff=lfs merge=lfs -text
|
| 61 |
+
Translations/Individual-Contest-Day1/Armenia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Armenia.docx filter=lfs diff=lfs merge=lfs -text
|
| 62 |
+
Translations/Individual-Contest-Day1/Bangladesh/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Bangladesh.docx filter=lfs diff=lfs merge=lfs -text
|
| 63 |
+
Translations/Individual-Contest-Day1/Benin/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Benin.docx filter=lfs diff=lfs merge=lfs -text
|
| 64 |
+
Translations/Individual-Contest-Day1/Brazil/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Brazil.docx filter=lfs diff=lfs merge=lfs -text
|
| 65 |
+
Translations/Individual-Contest-Day1/Bulgarian/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Bulgarian.docx filter=lfs diff=lfs merge=lfs -text
|
| 66 |
+
Translations/Individual-Contest-Day1/China/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeadTranslate_China_Simplified[[:space:]]Chinese.pdf filter=lfs diff=lfs merge=lfs -text
|
| 67 |
+
Translations/Individual-Contest-Day1/China/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeadTranslate_China.docx filter=lfs diff=lfs merge=lfs -text
|
| 68 |
+
Translations/Individual-Contest-Day1/Colombia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Colombia.docx filter=lfs diff=lfs merge=lfs -text
|
| 69 |
+
Translations/Individual-Contest-Day1/Elsalvador/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Elsalvador_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 70 |
+
Translations/Individual-Contest-Day1/Elsalvador/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Elsalvador_Spanish.docx filter=lfs diff=lfs merge=lfs -text
|
| 71 |
+
Translations/Individual-Contest-Day1/Estonia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Estonia.docx filter=lfs diff=lfs merge=lfs -text
|
| 72 |
+
Translations/Individual-Contest-Day1/France/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 73 |
+
Translations/Individual-Contest-Day1/Georgia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Georgian.docx filter=lfs diff=lfs merge=lfs -text
|
| 74 |
+
Translations/Individual-Contest-Day1/Greece/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Greece_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 75 |
+
Translations/Individual-Contest-Day1/Greece/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Greece.docx filter=lfs diff=lfs merge=lfs -text
|
| 76 |
+
Translations/Individual-Contest-Day1/HongKong[[:space:]]China/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_HongKong[[:space:]]China.docx filter=lfs diff=lfs merge=lfs -text
|
| 77 |
+
Translations/Individual-Contest-Day1/Hungary/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Hungary.docx filter=lfs diff=lfs merge=lfs -text
|
| 78 |
+
Translations/Individual-Contest-Day1/Hungary/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Hungary.pdf filter=lfs diff=lfs merge=lfs -text
|
| 79 |
+
Translations/Individual-Contest-Day1/India/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_India_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 80 |
+
Translations/Individual-Contest-Day1/Indonesia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Indonesian.docx filter=lfs diff=lfs merge=lfs -text
|
| 81 |
+
Translations/Individual-Contest-Day1/IOAI[[:space:]]TEAM/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_IOAI[[:space:]]TEAM_Ukrainian.docx filter=lfs diff=lfs merge=lfs -text
|
| 82 |
+
Translations/Individual-Contest-Day1/Iran/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Iran.pdf filter=lfs diff=lfs merge=lfs -text
|
| 83 |
+
Translations/Individual-Contest-Day1/Isle[[:space:]]of[[:space:]]Man/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Isle_of_Man_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 84 |
+
Translations/Individual-Contest-Day1/Jamaica/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Jamaica.docx filter=lfs diff=lfs merge=lfs -text
|
| 85 |
+
Translations/Individual-Contest-Day1/Japan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Japan_Japanese.docx filter=lfs diff=lfs merge=lfs -text
|
| 86 |
+
Translations/Individual-Contest-Day1/Kazakhstan/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Russian.docx filter=lfs diff=lfs merge=lfs -text
|
| 87 |
+
Translations/Individual-Contest-Day1/Kazakhstan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Kazakhstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 88 |
+
Translations/Individual-Contest-Day1/Kinyarwanda/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Kinyarwanda.docx filter=lfs diff=lfs merge=lfs -text
|
| 89 |
+
Translations/Individual-Contest-Day1/Kyrgyzstan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeadTranslate_Kyrgyzstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 90 |
+
Translations/Individual-Contest-Day1/Macao[[:space:]]China/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Macao[[:space:]]China.docx filter=lfs diff=lfs merge=lfs -text
|
| 91 |
+
Translations/Individual-Contest-Day1/Malaysia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeadTranslate_Malaysia_Malay.docx filter=lfs diff=lfs merge=lfs -text
|
| 92 |
+
Translations/Individual-Contest-Day1/Mali/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Mali_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 93 |
+
Translations/Individual-Contest-Day1/Mexico/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Mexico_Spanish.docx filter=lfs diff=lfs merge=lfs -text
|
| 94 |
+
Translations/Individual-Contest-Day1/Mongolia/Individual[[:space:]]Contest[[:space:]]Day1_Mongolian[[:space:]]-[[:space:]]translated.docx filter=lfs diff=lfs merge=lfs -text
|
| 95 |
+
Translations/Individual-Contest-Day1/Netherlands/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Netherlands_Dutch.docx filter=lfs diff=lfs merge=lfs -text
|
| 96 |
+
Translations/Individual-Contest-Day1/Netherlands/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Netherlands_Dutch.pdf filter=lfs diff=lfs merge=lfs -text
|
| 97 |
+
Translations/Individual-Contest-Day1/Pakistan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Pakistan.docx filter=lfs diff=lfs merge=lfs -text
|
| 98 |
+
Translations/Individual-Contest-Day1/Peru/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Peru.docx filter=lfs diff=lfs merge=lfs -text
|
| 99 |
+
Translations/Individual-Contest-Day1/Poland/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Poland_Polish.docx filter=lfs diff=lfs merge=lfs -text
|
| 100 |
+
Translations/Individual-Contest-Day1/Puerto[[:space:]]Rico/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Puerto_Rico.pdf filter=lfs diff=lfs merge=lfs -text
|
| 101 |
+
Translations/Individual-Contest-Day1/Romania/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Romania_Romanian.docx filter=lfs diff=lfs merge=lfs -text
|
| 102 |
+
Translations/Individual-Contest-Day1/Russia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Russian.docx filter=lfs diff=lfs merge=lfs -text
|
| 103 |
+
Translations/Individual-Contest-Day1/Serbia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Serbian.docx filter=lfs diff=lfs merge=lfs -text
|
| 104 |
+
Translations/Individual-Contest-Day1/Singapore/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Singapore_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 105 |
+
Translations/Individual-Contest-Day1/Singapore/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Singapore_English.pdf filter=lfs diff=lfs merge=lfs -text
|
| 106 |
+
Translations/Individual-Contest-Day1/South[[:space:]]Korea/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_South[[:space:]]Korea_Korean.docx filter=lfs diff=lfs merge=lfs -text
|
| 107 |
+
Translations/Individual-Contest-Day1/Sweden/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Swedish.docx filter=lfs diff=lfs merge=lfs -text
|
| 108 |
+
Translations/Individual-Contest-Day1/Thailand/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Thailand.docx filter=lfs diff=lfs merge=lfs -text
|
| 109 |
+
Translations/Individual-Contest-Day1/Thailand/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Thailand.pdf filter=lfs diff=lfs merge=lfs -text
|
| 110 |
+
Translations/Individual-Contest-Day1/Tunisia/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Tunisia_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 111 |
+
Translations/Individual-Contest-Day1/Turkiye/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Turkish_old[[:space:]]version.docx filter=lfs diff=lfs merge=lfs -text
|
| 112 |
+
Translations/Individual-Contest-Day1/Turkiye/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Turkish.docx filter=lfs diff=lfs merge=lfs -text
|
| 113 |
+
Translations/Individual-Contest-Day1/UK/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_UK_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 114 |
+
Translations/Individual-Contest-Day1/UK/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_UK_English.pdf filter=lfs diff=lfs merge=lfs -text
|
| 115 |
+
Translations/Individual-Contest-Day1/USA/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_USA_English.pdf filter=lfs diff=lfs merge=lfs -text
|
| 116 |
+
Translations/Individual-Contest-Day1/Uzbekistan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Uzbekistan-Eng.docx filter=lfs diff=lfs merge=lfs -text
|
| 117 |
+
Translations/Individual-Contest-Day1/Uzbekistan/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Uzbekistan-RU.docx filter=lfs diff=lfs merge=lfs -text
|
| 118 |
+
Translations/Individual-Contest-Day1/Venezuela/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Spanish_Venezuela.docx filter=lfs diff=lfs merge=lfs -text
|
| 119 |
+
Translations/Individual-Contest-Day1/Vietnam/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Vietnamese.docx filter=lfs diff=lfs merge=lfs -text
|
| 120 |
+
Translations/Individual-Contest-Day1/Vietnam/Individual[[:space:]]Contest[[:space:]]Day1_TeamLeaderTranslate_Vietnamese.pdf filter=lfs diff=lfs merge=lfs -text
|
| 121 |
+
Translations/Individual-Contest-Day2/Albania/Albania.docx filter=lfs diff=lfs merge=lfs -text
|
| 122 |
+
Translations/Individual-Contest-Day2/Armenia/Armenia.docx filter=lfs diff=lfs merge=lfs -text
|
| 123 |
+
Translations/Individual-Contest-Day2/Bangladesh/Bangladesh.docx filter=lfs diff=lfs merge=lfs -text
|
| 124 |
+
Translations/Individual-Contest-Day2/Benin/BENIN[[:space:]]-[[:space:]]Day[[:space:]]2.docx filter=lfs diff=lfs merge=lfs -text
|
| 125 |
+
Translations/Individual-Contest-Day2/Benin/BENIN[[:space:]]).docx filter=lfs diff=lfs merge=lfs -text
|
| 126 |
+
Translations/Individual-Contest-Day2/Benin/BENIN.docx filter=lfs diff=lfs merge=lfs -text
|
| 127 |
+
Translations/Individual-Contest-Day2/Brazil/Brazil.docx filter=lfs diff=lfs merge=lfs -text
|
| 128 |
+
Translations/Individual-Contest-Day2/Bulgarian/Bulgarian.docx filter=lfs diff=lfs merge=lfs -text
|
| 129 |
+
Translations/Individual-Contest-Day2/China/China.docx filter=lfs diff=lfs merge=lfs -text
|
| 130 |
+
Translations/Individual-Contest-Day2/China/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Simplified[[:space:]]Chinese.pdf filter=lfs diff=lfs merge=lfs -text
|
| 131 |
+
Translations/Individual-Contest-Day2/Colombia/Colombia[[:space:]]Day2.docx filter=lfs diff=lfs merge=lfs -text
|
| 132 |
+
Translations/Individual-Contest-Day2/Elsalvador/Individual[[:space:]]Contest[[:space:]]Day1_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 133 |
+
Translations/Individual-Contest-Day2/Elsalvador/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Spanish.docx filter=lfs diff=lfs merge=lfs -text
|
| 134 |
+
Translations/Individual-Contest-Day2/Estonia/Estonia_2.docx filter=lfs diff=lfs merge=lfs -text
|
| 135 |
+
Translations/Individual-Contest-Day2/France/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 136 |
+
Translations/Individual-Contest-Day2/France/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 137 |
+
Translations/Individual-Contest-Day2/Georgia/Individual[[:space:]]Contest[[:space:]]Day1_Georgian.docx filter=lfs diff=lfs merge=lfs -text
|
| 138 |
+
Translations/Individual-Contest-Day2/Georgia/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Georgian.docx filter=lfs diff=lfs merge=lfs -text
|
| 139 |
+
Translations/Individual-Contest-Day2/Greece/Greece[[:space:]]Day[[:space:]]2_.docx filter=lfs diff=lfs merge=lfs -text
|
| 140 |
+
Translations/Individual-Contest-Day2/Greece/Greece[[:space:]]Day[[:space:]]2.docx filter=lfs diff=lfs merge=lfs -text
|
| 141 |
+
Translations/Individual-Contest-Day2/HongKong[[:space:]]China/中國香港.docx filter=lfs diff=lfs merge=lfs -text
|
| 142 |
+
Translations/Individual-Contest-Day2/Hungary/Hungary.docx filter=lfs diff=lfs merge=lfs -text
|
| 143 |
+
Translations/Individual-Contest-Day2/Hungary/Hungary.pdf filter=lfs diff=lfs merge=lfs -text
|
| 144 |
+
Translations/Individual-Contest-Day2/Hungary/HungaryDay2.docx filter=lfs diff=lfs merge=lfs -text
|
| 145 |
+
Translations/Individual-Contest-Day2/India/Individual[[:space:]]Contest[[:space:]]Day1_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 146 |
+
Translations/Individual-Contest-Day2/India/Individual[[:space:]]Contest[[:space:]]Day2_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 147 |
+
Translations/Individual-Contest-Day2/Indonesia/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Indonesian.docx filter=lfs diff=lfs merge=lfs -text
|
| 148 |
+
Translations/Individual-Contest-Day2/Indonesia/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Indonesian.docx filter=lfs diff=lfs merge=lfs -text
|
| 149 |
+
Translations/Individual-Contest-Day2/IOAI[[:space:]]TEAM/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Ukrainian.docx filter=lfs diff=lfs merge=lfs -text
|
| 150 |
+
Translations/Individual-Contest-Day2/IOAI[[:space:]]TEAM/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Ukrainian.docx filter=lfs diff=lfs merge=lfs -text
|
| 151 |
+
Translations/Individual-Contest-Day2/Iran/Iran.pdf filter=lfs diff=lfs merge=lfs -text
|
| 152 |
+
Translations/Individual-Contest-Day2/Isle[[:space:]]of[[:space:]]Man/Isle_of_Man_English.docx filter=lfs diff=lfs merge=lfs -text
|
| 153 |
+
Translations/Individual-Contest-Day2/Jamaica/jamaica.docx filter=lfs diff=lfs merge=lfs -text
|
| 154 |
+
Translations/Individual-Contest-Day2/Japan/Japanese.docx filter=lfs diff=lfs merge=lfs -text
|
| 155 |
+
Translations/Individual-Contest-Day2/Kazakhstan/Day2/Kazakhstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 156 |
+
Translations/Individual-Contest-Day2/Kazakhstan/Kazakhstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 157 |
+
Translations/Individual-Contest-Day2/Kazakhstan/New[[:space:]]folder/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Russian.docx filter=lfs diff=lfs merge=lfs -text
|
| 158 |
+
Translations/Individual-Contest-Day2/Kinyarwanda/Individual[[:space:]]Contest[[:space:]]Day1_Kinyarwanda.docx filter=lfs diff=lfs merge=lfs -text
|
| 159 |
+
Translations/Individual-Contest-Day2/Kinyarwanda/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Kinyarwanda.docx filter=lfs diff=lfs merge=lfs -text
|
| 160 |
+
Translations/Individual-Contest-Day2/Kyrgyzstan/DAY[[:space:]]2/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_kyrgyzstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 161 |
+
Translations/Individual-Contest-Day2/Kyrgyzstan/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Kyrgyzstan.docx filter=lfs diff=lfs merge=lfs -text
|
| 162 |
+
Translations/Individual-Contest-Day2/Macao[[:space:]]China/Individual[[:space:]]Contest[[:space:]]Day1_Macao.docx filter=lfs diff=lfs merge=lfs -text
|
| 163 |
+
Translations/Individual-Contest-Day2/Macao[[:space:]]China/Individual[[:space:]]Contest[[:space:]]Day2_Macao.docx filter=lfs diff=lfs merge=lfs -text
|
| 164 |
+
Translations/Individual-Contest-Day2/Malaysia/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Malay_Malaysia.docx filter=lfs diff=lfs merge=lfs -text
|
| 165 |
+
Translations/Individual-Contest-Day2/Malaysia/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Malay_Malaysia.docx filter=lfs diff=lfs merge=lfs -text
|
| 166 |
+
Translations/Individual-Contest-Day2/Mali/GAITE[[:space:]]Day1_MachineTranslate_French_Mali.docx filter=lfs diff=lfs merge=lfs -text
|
| 167 |
+
Translations/Individual-Contest-Day2/Mali/GAITE[[:space:]]Day2_MachineTranslate_French_Mali.docx filter=lfs diff=lfs merge=lfs -text
|
| 168 |
+
Translations/Individual-Contest-Day2/Mexico/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_SpanishMexico.docx filter=lfs diff=lfs merge=lfs -text
|
| 169 |
+
Translations/Individual-Contest-Day2/Mexico/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Spanish_Mexico.docx filter=lfs diff=lfs merge=lfs -text
|
| 170 |
+
Translations/Individual-Contest-Day2/Mongolia/Individual[[:space:]]Contest[[:space:]]Day1_Mongolian[[:space:]]-[[:space:]]translated.docx filter=lfs diff=lfs merge=lfs -text
|
| 171 |
+
Translations/Individual-Contest-Day2/Mongolia/Individual[[:space:]]Contest[[:space:]]Day2_Mongolian.docx filter=lfs diff=lfs merge=lfs -text
|
| 172 |
+
Translations/Individual-Contest-Day2/Netherlands/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Dutch.docx filter=lfs diff=lfs merge=lfs -text
|
| 173 |
+
Translations/Individual-Contest-Day2/Netherlands/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Dutch.pdf filter=lfs diff=lfs merge=lfs -text
|
| 174 |
+
Translations/Individual-Contest-Day2/Netherlands/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Dutch.docx filter=lfs diff=lfs merge=lfs -text
|
| 175 |
+
Translations/Individual-Contest-Day2/Netherlands/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Dutch.pdf filter=lfs diff=lfs merge=lfs -text
|
| 176 |
+
Translations/Individual-Contest-Day2/Pakistan/Individual[[:space:]]Contest[[:space:]]Day2_English[[:space:]]Pakistan.docx filter=lfs diff=lfs merge=lfs -text
|
| 177 |
+
Translations/Individual-Contest-Day2/Pakistan/pakistan[[:space:]]document.docx filter=lfs diff=lfs merge=lfs -text
|
| 178 |
+
Translations/Individual-Contest-Day2/Peru/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Spanish_Peru.docx filter=lfs diff=lfs merge=lfs -text
|
| 179 |
+
Translations/Individual-Contest-Day2/Poland/Individual[[:space:]]Contest[[:space:]]Day1_Polish.docx filter=lfs diff=lfs merge=lfs -text
|
| 180 |
+
Translations/Individual-Contest-Day2/Poland/Individual[[:space:]]Contest[[:space:]]Day2_Polish.docx filter=lfs diff=lfs merge=lfs -text
|
| 181 |
+
Translations/Individual-Contest-Day2/Puerto[[:space:]]Rico/GAITE[[:space:]]Day1_English_Puerto_Rico.pdf filter=lfs diff=lfs merge=lfs -text
|
| 182 |
+
Translations/Individual-Contest-Day2/Puerto[[:space:]]Rico/GAITE[[:space:]]Day2_English_Puerto_Rico.pdf filter=lfs diff=lfs merge=lfs -text
|
| 183 |
+
Translations/Individual-Contest-Day2/Romania/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Romanian.docx filter=lfs diff=lfs merge=lfs -text
|
| 184 |
+
Translations/Individual-Contest-Day2/Romania/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Romanian.docx filter=lfs diff=lfs merge=lfs -text
|
| 185 |
+
Translations/Individual-Contest-Day2/Russia/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Russian.docx filter=lfs diff=lfs merge=lfs -text
|
| 186 |
+
Translations/Individual-Contest-Day2/Russia/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Russia.docx filter=lfs diff=lfs merge=lfs -text
|
| 187 |
+
Translations/Individual-Contest-Day2/Saudi[[:space:]]Arabia/Individual[[:space:]]Contest[[:space:]]Day2_English_SaudiArabia.docx filter=lfs diff=lfs merge=lfs -text
|
| 188 |
+
Translations/Individual-Contest-Day2/Serbia/Individual[[:space:]]Contest[[:space:]]Day1_Serbian.docx filter=lfs diff=lfs merge=lfs -text
|
| 189 |
+
Translations/Individual-Contest-Day2/Serbia/Individual[[:space:]]Contest[[:space:]]Day2_Serbian.docx filter=lfs diff=lfs merge=lfs -text
|
| 190 |
+
Translations/Individual-Contest-Day2/Singapore/Individual[[:space:]]Contest[[:space:]]Day1_English[[:space:]]-[[:space:]]Singapore.docx filter=lfs diff=lfs merge=lfs -text
|
| 191 |
+
Translations/Individual-Contest-Day2/Singapore/Individual[[:space:]]Contest[[:space:]]Day1_English[[:space:]]-[[:space:]]Singapore.pdf filter=lfs diff=lfs merge=lfs -text
|
| 192 |
+
Translations/Individual-Contest-Day2/Singapore/Individual[[:space:]]Contest[[:space:]]Day2_English_Singapore.docx filter=lfs diff=lfs merge=lfs -text
|
| 193 |
+
Translations/Individual-Contest-Day2/South[[:space:]]Korea/Individual[[:space:]]Contest[[:space:]]Day1_Korean.docx filter=lfs diff=lfs merge=lfs -text
|
| 194 |
+
Translations/Individual-Contest-Day2/South[[:space:]]Korea/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Korean.docx filter=lfs diff=lfs merge=lfs -text
|
| 195 |
+
Translations/Individual-Contest-Day2/Sweden/SwedenDay2.docx filter=lfs diff=lfs merge=lfs -text
|
| 196 |
+
Translations/Individual-Contest-Day2/Sweden/Swedish.docx filter=lfs diff=lfs merge=lfs -text
|
| 197 |
+
Translations/Individual-Contest-Day2/Thailand/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Thai.docx filter=lfs diff=lfs merge=lfs -text
|
| 198 |
+
Translations/Individual-Contest-Day2/Thailand/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Thai.pdf filter=lfs diff=lfs merge=lfs -text
|
| 199 |
+
Translations/Individual-Contest-Day2/Tunisia/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 200 |
+
Translations/Individual-Contest-Day2/Tunisia/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_French.docx filter=lfs diff=lfs merge=lfs -text
|
| 201 |
+
Translations/Individual-Contest-Day2/Turkiye/DONOTPRINTTHEFILESINTHIS/Individual[[:space:]]Contest[[:space:]]Day1_Turkish.docx filter=lfs diff=lfs merge=lfs -text
|
| 202 |
+
Translations/Individual-Contest-Day2/Turkiye/DONOTPRINTTHEFILESINTHIS/OLD2Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Turkish_20250806_01.docx filter=lfs diff=lfs merge=lfs -text
|
| 203 |
+
Translations/Individual-Contest-Day2/Turkiye/DONOTPRINTTHEFILESINTHIS/OLDIndividual[[:space:]]Contest[[:space:]]Day1_Turkish_old.docx filter=lfs diff=lfs merge=lfs -text
|
| 204 |
+
Translations/Individual-Contest-Day2/Turkiye/DONOTPRINTTHEFILESINTHIS/OLDIndividual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Turkish_20250806_01.docx filter=lfs diff=lfs merge=lfs -text
|
| 205 |
+
Translations/Individual-Contest-Day2/Turkiye/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Turkish_20250806_01.docx filter=lfs diff=lfs merge=lfs -text
|
| 206 |
+
Translations/Individual-Contest-Day2/UK/Individual[[:space:]]Contest[[:space:]]Day1_English_UK.docx filter=lfs diff=lfs merge=lfs -text
|
| 207 |
+
Translations/Individual-Contest-Day2/UK/Individual[[:space:]]Contest[[:space:]]Day1_English_UK.pdf filter=lfs diff=lfs merge=lfs -text
|
| 208 |
+
Translations/Individual-Contest-Day2/UK/Individual[[:space:]]Contest[[:space:]]Day2_English_UK.docx filter=lfs diff=lfs merge=lfs -text
|
| 209 |
+
Translations/Individual-Contest-Day2/USA/Individual[[:space:]]Contest[[:space:]]Day2_English[[:space:]]-[[:space:]]USA.pdf filter=lfs diff=lfs merge=lfs -text
|
| 210 |
+
Translations/Individual-Contest-Day2/Uzbekistan/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Russian.docx filter=lfs diff=lfs merge=lfs -text
|
| 211 |
+
Translations/Individual-Contest-Day2/Uzbekistan/Uzbekistan-Eng.docx filter=lfs diff=lfs merge=lfs -text
|
| 212 |
+
Translations/Individual-Contest-Day2/Uzbekistan/Uzbekistan-RU.docx filter=lfs diff=lfs merge=lfs -text
|
| 213 |
+
Translations/Individual-Contest-Day2/Venezuela/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Spanish_Venezuela.docx filter=lfs diff=lfs merge=lfs -text
|
| 214 |
+
Translations/Individual-Contest-Day2/Venezuela/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Spanish_Venezuela.docx filter=lfs diff=lfs merge=lfs -text
|
| 215 |
+
Translations/Individual-Contest-Day2/Vietnam/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Vietnamese.docx filter=lfs diff=lfs merge=lfs -text
|
| 216 |
+
Translations/Individual-Contest-Day2/Vietnam/Individual[[:space:]]Contest[[:space:]]Day1_MachineTranslate_Vietnamese.pdf filter=lfs diff=lfs merge=lfs -text
|
| 217 |
+
Translations/Individual-Contest-Day2/Vietnam/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Vietnamese.docx filter=lfs diff=lfs merge=lfs -text
|
| 218 |
+
Translations/Individual-Contest-Day2/Vietnam/Individual[[:space:]]Contest[[:space:]]Day2_MachineTranslate_Vietnamese.pdf filter=lfs diff=lfs merge=lfs -text
|
| 219 |
+
Individual-Contest/Radar/Solution/validation_set/labels/ground_truth_val.csv filter=lfs diff=lfs merge=lfs -text
|
| 220 |
+
Individual-Contest/Radar/Solution/test_set/labels/ground_truth_test.csv filter=lfs diff=lfs merge=lfs -text
|
benchmark/IOAI/IOAI2025/Individual-Contest/Antique/Antique.ipynb
ADDED
|
@@ -0,0 +1,236 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"id": "6fe78d59-1f8b-41fb-b8db-9927b8ed049e",
|
| 6 |
+
"metadata": {},
|
| 7 |
+
"source": [
|
| 8 |
+
"<img src=\"./figs/IOAI-Logo.png\" alt=\"IOAI Logo\" width=\"200\" height=\"auto\">\n",
|
| 9 |
+
"\n",
|
| 10 |
+
"[IOAI 2025 (Beijing, China), Individual Contest](https://ioai-official.org/china-2025)\n",
|
| 11 |
+
"\n",
|
| 12 |
+
"[](https://colab.research.google.com/github/IOAI-official/IOAI-2025/blob/main/Individual-Contest/Antique/Antique.ipynb)"
|
| 13 |
+
]
|
| 14 |
+
},
|
| 15 |
+
{
|
| 16 |
+
"cell_type": "markdown",
|
| 17 |
+
"id": "a4c6054c-d42b-4c2b-bb79-deb64d936c24",
|
| 18 |
+
"metadata": {},
|
| 19 |
+
"source": [
|
| 20 |
+
"# Antique Painting Authentication\n",
|
| 21 |
+
"\n",
|
| 22 |
+
"## 1. Problem Description\n",
|
| 23 |
+
"\n",
|
| 24 |
+
"You have studied Artificial Intelligence for quite some time. Old friend of your father, famous archeologist and art critic, heard about this and asked for your help. You need to design an algorithm that can classify antique paintings as either authentic or replica pieces.\n",
|
| 25 |
+
"\n",
|
| 26 |
+
"Because professional authentication is expensive, the research team has only obtained authenticity labels for a small portion of the paintings. For the majority of samples, the authenticity remains unknown. It is known that the paintings' digital features exhibit strong structural patterns. You are tasked with leveraging all available samples — including those with unknown labels — to train a model for classifying the authenticity of antique paintings.\n",
|
| 27 |
+
"\n",
|
| 28 |
+
"## 2. Dataset\n",
|
| 29 |
+
"\n",
|
| 30 |
+
"The dataset consists of a training set, a validation set and a test set, each of them has 500 independent samples. \n",
|
| 31 |
+
"\n",
|
| 32 |
+
"1. **Training Set (`training_set.csv`)**:\n",
|
| 33 |
+
"\n",
|
| 34 |
+
" - The first five columns represent the digital features of each antique painting.\n",
|
| 35 |
+
" - The sixth column contains the label: 1 for authentic, -1 for replica, and 0 for unknown.\n",
|
| 36 |
+
"\n",
|
| 37 |
+
" The training set is used for training your models and can be accessed and downloaded directly during the competition.\n",
|
| 38 |
+
"\n",
|
| 39 |
+
"2. **Validation Set (`validation_set.csv`)**: \n",
|
| 40 |
+
" - These are similar to the training set format but do not contain the label column.\n",
|
| 41 |
+
"\n",
|
| 42 |
+
" The validation set is used to calculate the Leaderboard A score and is not directly accessible during the competition.\n",
|
| 43 |
+
"\n",
|
| 44 |
+
"3. **Test Set (`test_set.csv`)**: \n",
|
| 45 |
+
" - These are similar to the training set format but do not contain the label column.\n",
|
| 46 |
+
"\n",
|
| 47 |
+
" The test set is used to calculate the Leaderboard B score and is not directly accessible during the competition.\n",
|
| 48 |
+
"\n",
|
| 49 |
+
"## 3. Task\n",
|
| 50 |
+
"\n",
|
| 51 |
+
"Your task is to train an appropriate model capable of predicting the authenticity of paintings in the test sets, despite the large number of unlabeled samples.\n",
|
| 52 |
+
"\n",
|
| 53 |
+
"## 4. Submission\n",
|
| 54 |
+
"\n",
|
| 55 |
+
"Contestants need to submit a notebook file named `submission.ipynb`. The file should output a zip file named `submission.zip`, which should contain the following two files:\n",
|
| 56 |
+
"\n",
|
| 57 |
+
"1. `submissionA.csv`: Contains the model's predicted label results on the validation set, with each line being a -1 or 1 and no header.\n",
|
| 58 |
+
"2. `submissionB.csv`: Contains the model's predicted label results on the test set, with each line being a -1 or 1 and no header.\n",
|
| 59 |
+
"\n",
|
| 60 |
+
"The testing machine will read `submission.zip` and calculate the scores. The submission files must strictly follow the above format and naming; otherwise, the system will not be able to read them correctly. \n",
|
| 61 |
+
"\n",
|
| 62 |
+
"Details about the submission procedure are provided in the baseline notebook. Contestants are encouraged to refer to it for guidance.\n",
|
| 63 |
+
"\n",
|
| 64 |
+
"## 5. Score\n",
|
| 65 |
+
"\n",
|
| 66 |
+
"The evaluation metric will be **classification accuracy**, defined as the proportion of correctly predicted samples over the total number of evaluated samples.\n",
|
| 67 |
+
"\n",
|
| 68 |
+
"## 6. Baseline and Training Set\n",
|
| 69 |
+
"\n",
|
| 70 |
+
"- Below you can find the baseline solution.\n",
|
| 71 |
+
"- The dataset is in `training_set` folder.\n",
|
| 72 |
+
"- The highest score by the Scientific Committee for this task is 0.98 in Leaderboard B, this score is used for score unification.\n",
|
| 73 |
+
"- The baseline score by the Scientific Committee for this task is 0.46 in Leaderboard B, this score is used for score unification."
|
| 74 |
+
]
|
| 75 |
+
},
|
| 76 |
+
{
|
| 77 |
+
"cell_type": "markdown",
|
| 78 |
+
"id": "44bf0dce",
|
| 79 |
+
"metadata": {},
|
| 80 |
+
"source": [
|
| 81 |
+
"### Train Your Model"
|
| 82 |
+
]
|
| 83 |
+
},
|
| 84 |
+
{
|
| 85 |
+
"cell_type": "code",
|
| 86 |
+
"execution_count": null,
|
| 87 |
+
"id": "3acb09be",
|
| 88 |
+
"metadata": {},
|
| 89 |
+
"outputs": [],
|
| 90 |
+
"source": [
|
| 91 |
+
"import os\n",
|
| 92 |
+
"import sys\n",
|
| 93 |
+
"\n",
|
| 94 |
+
"# 1. Get the current working directory\n",
|
| 95 |
+
"current_dir = os.getcwd()\n",
|
| 96 |
+
"\n",
|
| 97 |
+
"# 2. Check if the path contains \"Individual-Contest/Antique\" and trim it to that point\n",
|
| 98 |
+
"if \"Individual-Contest/Antique\" in current_dir:\n",
|
| 99 |
+
" root_index = current_dir.index(\"Individual-Contest/Antique\") + len(\"Individual-Contest/Antique\")\n",
|
| 100 |
+
" project_root = current_dir[:root_index]\n",
|
| 101 |
+
"else:\n",
|
| 102 |
+
" raise Exception(\"Project root directory not found. Please check the folder structure.\")\n",
|
| 103 |
+
"\n",
|
| 104 |
+
"# 3. Change working directory to the project root\n",
|
| 105 |
+
"os.chdir(project_root)\n",
|
| 106 |
+
"print(\"Working directory set to:\", os.getcwd())\n",
|
| 107 |
+
"\n",
|
| 108 |
+
"# 4. Add module search path (e.g., where metrics.py is located)\n",
|
| 109 |
+
"sys.path.append(os.path.join(project_root, \"Scoring\"))"
|
| 110 |
+
]
|
| 111 |
+
},
|
| 112 |
+
{
|
| 113 |
+
"cell_type": "code",
|
| 114 |
+
"execution_count": null,
|
| 115 |
+
"id": "03dae883",
|
| 116 |
+
"metadata": {},
|
| 117 |
+
"outputs": [],
|
| 118 |
+
"source": [
|
| 119 |
+
"import pandas as pd\n",
|
| 120 |
+
"import numpy as np\n",
|
| 121 |
+
"import os\n",
|
| 122 |
+
"from sklearn.svm import SVC\n",
|
| 123 |
+
"\n",
|
| 124 |
+
"TRAIN_PATH = \"./training_set/\"\n",
|
| 125 |
+
"train = pd.read_csv(TRAIN_PATH + \"training_set.csv\")\n",
|
| 126 |
+
"\n",
|
| 127 |
+
"X = np.array(train.iloc[:,:5])\n",
|
| 128 |
+
"y = np.array(train.iloc[:,5])\n",
|
| 129 |
+
"\n",
|
| 130 |
+
"np.random.seed(42)\n",
|
| 131 |
+
"y[y == 0] = np.random.choice([-1, 1], size=(y == 0).sum())\n",
|
| 132 |
+
"\n",
|
| 133 |
+
"svm_binary_model = SVC(kernel='rbf', C=1.0, gamma='scale', random_state=42)\n",
|
| 134 |
+
"svm_binary_model.fit(X, y)"
|
| 135 |
+
]
|
| 136 |
+
},
|
| 137 |
+
{
|
| 138 |
+
"cell_type": "markdown",
|
| 139 |
+
"id": "a2049ba4",
|
| 140 |
+
"metadata": {},
|
| 141 |
+
"source": [
|
| 142 |
+
"### Make Predictions on the Validation and Test Set"
|
| 143 |
+
]
|
| 144 |
+
},
|
| 145 |
+
{
|
| 146 |
+
"cell_type": "code",
|
| 147 |
+
"execution_count": null,
|
| 148 |
+
"id": "c69d9d92",
|
| 149 |
+
"metadata": {},
|
| 150 |
+
"outputs": [],
|
| 151 |
+
"source": [
|
| 152 |
+
"VAL_DATA_PATH = \"./Solution/validation_set/\"\n",
|
| 153 |
+
"TEST_DATA_PATH = \"./Solution/test_set/\"\n",
|
| 154 |
+
"\n",
|
| 155 |
+
"testA = np.array(pd.read_csv(VAL_DATA_PATH + \"validation_set.csv\"))\n",
|
| 156 |
+
"testB = np.array(pd.read_csv(TEST_DATA_PATH + \"test_set.csv\"))\n",
|
| 157 |
+
"\n",
|
| 158 |
+
"predA = svm_binary_model.predict(testA)\n",
|
| 159 |
+
"predB = svm_binary_model.predict(testB)"
|
| 160 |
+
]
|
| 161 |
+
},
|
| 162 |
+
{
|
| 163 |
+
"cell_type": "markdown",
|
| 164 |
+
"id": "3e2141d8",
|
| 165 |
+
"metadata": {},
|
| 166 |
+
"source": [
|
| 167 |
+
"### Generate `submission.zip` for Submission"
|
| 168 |
+
]
|
| 169 |
+
},
|
| 170 |
+
{
|
| 171 |
+
"cell_type": "code",
|
| 172 |
+
"execution_count": null,
|
| 173 |
+
"id": "342e6ddb",
|
| 174 |
+
"metadata": {},
|
| 175 |
+
"outputs": [],
|
| 176 |
+
"source": [
|
| 177 |
+
"import zipfile\n",
|
| 178 |
+
"import os\n",
|
| 179 |
+
"\n",
|
| 180 |
+
"submissionA = pd.DataFrame(predA)\n",
|
| 181 |
+
"submissionA.to_csv(\"./Scoring/submissionA.csv\", index=False, header=False)\n",
|
| 182 |
+
"\n",
|
| 183 |
+
"submissionB = pd.DataFrame(predB)\n",
|
| 184 |
+
"submissionB.to_csv(\"./Scoring/submissionB.csv\", index=False, header=False)\n",
|
| 185 |
+
"\n",
|
| 186 |
+
"files_to_zip = ['./Scoring/submissionA.csv', './Scoring/submissionB.csv']\n",
|
| 187 |
+
"zip_filename = './Scoring/submission.zip'\n",
|
| 188 |
+
"\n",
|
| 189 |
+
"with zipfile.ZipFile(zip_filename, 'w') as zipf:\n",
|
| 190 |
+
" for file in files_to_zip:\n",
|
| 191 |
+
" zipf.write(file, os.path.basename(file))\n",
|
| 192 |
+
"\n",
|
| 193 |
+
"print(f'{zip_filename} is created succefully!')"
|
| 194 |
+
]
|
| 195 |
+
},
|
| 196 |
+
{
|
| 197 |
+
"cell_type": "markdown",
|
| 198 |
+
"id": "25da701b",
|
| 199 |
+
"metadata": {},
|
| 200 |
+
"source": [
|
| 201 |
+
"### Evaluate the Model Performance"
|
| 202 |
+
]
|
| 203 |
+
},
|
| 204 |
+
{
|
| 205 |
+
"cell_type": "code",
|
| 206 |
+
"execution_count": null,
|
| 207 |
+
"id": "269246ef",
|
| 208 |
+
"metadata": {},
|
| 209 |
+
"outputs": [],
|
| 210 |
+
"source": [
|
| 211 |
+
"%run Scoring/metrics.py"
|
| 212 |
+
]
|
| 213 |
+
}
|
| 214 |
+
],
|
| 215 |
+
"metadata": {
|
| 216 |
+
"kernelspec": {
|
| 217 |
+
"display_name": "py9",
|
| 218 |
+
"language": "python",
|
| 219 |
+
"name": "python3"
|
| 220 |
+
},
|
| 221 |
+
"language_info": {
|
| 222 |
+
"codemirror_mode": {
|
| 223 |
+
"name": "ipython",
|
| 224 |
+
"version": 3
|
| 225 |
+
},
|
| 226 |
+
"file_extension": ".py",
|
| 227 |
+
"mimetype": "text/x-python",
|
| 228 |
+
"name": "python",
|
| 229 |
+
"nbconvert_exporter": "python",
|
| 230 |
+
"pygments_lexer": "ipython3",
|
| 231 |
+
"version": "3.9.23"
|
| 232 |
+
}
|
| 233 |
+
},
|
| 234 |
+
"nbformat": 4,
|
| 235 |
+
"nbformat_minor": 5
|
| 236 |
+
}
|
benchmark/IOAI/IOAI2025/Individual-Contest/Antique/score.json
ADDED
|
@@ -0,0 +1 @@
|
|
|
|
|
|
|
| 1 |
+
{"status": true, "score": {"public_a": 0.984, "public_detail": {"Accuracy": 0.984}, "private_b": 0.98, "private_detail": {"Accuracy": 0.98}}, "msg": "Success!"}
|
benchmark/IOAI/IOAI2025/Individual-Contest/Chicken_Counting/Chicken_Counting.ipynb
ADDED
|
@@ -0,0 +1,619 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"metadata": {},
|
| 6 |
+
"source": [
|
| 7 |
+
"<img src=\"./figs/IOAI-Logo.png\" alt=\"IOAI Logo\" width=\"200\" height=\"auto\">\n",
|
| 8 |
+
"\n",
|
| 9 |
+
"[IOAI 2025 (Beijing, China), Individual Contest](https://ioai-official.org/china-2025)\n",
|
| 10 |
+
"\n",
|
| 11 |
+
"[](https://colab.research.google.com/github/IOAI-official/IOAI-2025/blob/main/Individual-Contest/Chicken_Counting/Chicken_Counting.ipynb)"
|
| 12 |
+
]
|
| 13 |
+
},
|
| 14 |
+
{
|
| 15 |
+
"cell_type": "markdown",
|
| 16 |
+
"metadata": {},
|
| 17 |
+
"source": [
|
| 18 |
+
"# Chicken Counting\n",
|
| 19 |
+
"\n",
|
| 20 |
+
"## **1. Problem Description**\n",
|
| 21 |
+
"\n",
|
| 22 |
+
"As the leader of an AI research team collaborating with Silkie chicken farmers, you are tasked with solving a critical challenge in traditional free-range farming. Accurate counting of livestock is crucial for both farmers and insurance companies, as factors like disease outbreaks and predator invasions can significantly impact the survival rate of these chickens in a short time. While insurance coverage helps mitigate farming risks, the claims process requires precise counting of livestock losses. Your farmers have approached your team for help in developing more accurate, automated counting systems. The challenge before your research team is to develop an optimized Silkie chicken counting model using density estimation techniques that can provide reliable counts to support both farm management and insurance processes.\n",
|
| 23 |
+
"\n",
|
| 24 |
+
"Your team has access to a pretrained feature extractor for Silkie chicken images, but you'll need to design and train the density estimation decoder to create a complete counting solution. Your task is to build upon this foundation by developing an effective decoder architecture and training strategy to achieve accurate chicken counts that farmers and insurance companies can rely on.\n",
|
| 25 |
+
"\n",
|
| 26 |
+
"The below figure shows an image in the dataset, as well as the corresponding true density distribution and a predicted density distribution generated by the baseline model. The total density (sum of densities across all areas) is labeled.\n",
|
| 27 |
+
"\n",
|
| 28 |
+
"<img src=\"./figs/Chicken Counting Fig 1.png\" width=\"800\">\n",
|
| 29 |
+
"\n",
|
| 30 |
+
"## **2. Dataset**\n",
|
| 31 |
+
"\n",
|
| 32 |
+
"The structure of the provided Silkie chicken image dataset is as follows:\n",
|
| 33 |
+
"\n",
|
| 34 |
+
"```\n",
|
| 35 |
+
"datasets/\n",
|
| 36 |
+
"├── train/\n",
|
| 37 |
+
"│ └── A dataset with features:\n",
|
| 38 |
+
"│ ├── `image`: `PIL.Image` with RGB channels (3x720x1280)\n",
|
| 39 |
+
"│ └── `density`: a 2D array of shape 180x320\n",
|
| 40 |
+
"└── base.pth (Pretrained Model)\n",
|
| 41 |
+
"\n",
|
| 42 |
+
"\n",
|
| 43 |
+
"os.environ.get(\"DATA_PATH\")/\n",
|
| 44 |
+
"├── test_a/\n",
|
| 45 |
+
"│ └── A dataset with features:\n",
|
| 46 |
+
"│ └── `image`: `PIL.Image` with RGB channels (3x720x1280)\n",
|
| 47 |
+
"└── test_b/\n",
|
| 48 |
+
" └── A dataset with features:\n",
|
| 49 |
+
" └── `image`: `PIL.Image` with RGB channels (3x720x1280)\n",
|
| 50 |
+
"```\n",
|
| 51 |
+
"\n",
|
| 52 |
+
"(1) Training set location: `datasets`, files in this folder are used for model fine-tuning. It contains a train folder, which stores a dataset with 100 images and their corresponding density maps.\n",
|
| 53 |
+
"\n",
|
| 54 |
+
"(2) Validation set (test_a) and Test set (test_b): These will be used to evaluate scores on Leaderboard A and Leaderboard B, respectively. They will be inaccessible to contestants. Only the score achieved on test set B will be used for final scoring. \n",
|
| 55 |
+
"\n",
|
| 56 |
+
"(3) Datasets size:\n",
|
| 57 |
+
"\n",
|
| 58 |
+
"- Training set: 100 images.\n",
|
| 59 |
+
"- Validation set: 100 images.\n",
|
| 60 |
+
"- Test set: 100 images.\n",
|
| 61 |
+
"\n",
|
| 62 |
+
"(4) Validation set (test_a) and Test set (test_b) are not visible.\n",
|
| 63 |
+
"\n",
|
| 64 |
+
"(5) Due to limits of computing resources, training density maps are reshaped to $1\\times 180 \\times 320$. **NOTE** the output density map can be viewed as a 2D real number matrix with shape $180\\times 320$, the sum of all matrix values is the count of chickens.\n",
|
| 65 |
+
"\n",
|
| 66 |
+
"## **3. Task**\n",
|
| 67 |
+
"\n",
|
| 68 |
+
"Your task is to train your own model using the training data to predict density maps, thereby serving the purpose of chicken counting.\n",
|
| 69 |
+
"\n",
|
| 70 |
+
"You may extend and optimize the given pretrained model to improve its count prediction accuracy. The pretrained model `base.pth` only contains the weights of the first four layers of the model (the feature extraction model), and the function `load_pretrained_weights_partial` in the baseline code can be used to load these partial weights into your model. You may construct a density decoder `DensityDecoder` and combine it with the pretrained feature extraction module to form a complete data prediction model.\n",
|
| 71 |
+
"\n",
|
| 72 |
+
"```\n",
|
| 73 |
+
"class DensityDecoder(nn.Module):\n",
|
| 74 |
+
" def __init__(self):\n",
|
| 75 |
+
" #################################################\n",
|
| 76 |
+
" # Your code here\n",
|
| 77 |
+
" #################################################\n",
|
| 78 |
+
"\n",
|
| 79 |
+
" def forward(self, x):\n",
|
| 80 |
+
" #################################################\n",
|
| 81 |
+
" # Your code here\n",
|
| 82 |
+
" #################################################\n",
|
| 83 |
+
" return x\n",
|
| 84 |
+
"```\n",
|
| 85 |
+
"\n",
|
| 86 |
+
"You can also build your own model without the pretrained model we provided.\n",
|
| 87 |
+
"\n",
|
| 88 |
+
"This task is the continuation of Satellite Weather Forecasting. A kind remind is the UNET is easily to full GPU memory without any feature engineering. Then, the GPU memory error message will be reported. \n",
|
| 89 |
+
"\n",
|
| 90 |
+
"Please follow these rules to achieve a score normally:\n",
|
| 91 |
+
"\n",
|
| 92 |
+
"(1) Your model must output the predicted density map.\n",
|
| 93 |
+
"\n",
|
| 94 |
+
"(2) Due to limits of computing resources, your output density map should be reshaped to $180 \\times 320$. This is also the shape of target density maps provided in the train dataset.\n",
|
| 95 |
+
"\n",
|
| 96 |
+
"## 4. Submission\n",
|
| 97 |
+
"\n",
|
| 98 |
+
"Please submit a **submission.ipynb** that includes the following components:\n",
|
| 99 |
+
"\n",
|
| 100 |
+
"(1)**Training Code** \n",
|
| 101 |
+
"\n",
|
| 102 |
+
"- Include the full training pipeline.\n",
|
| 103 |
+
"\n",
|
| 104 |
+
"(2)**Evaluation Code**\n",
|
| 105 |
+
"- Evaluate your model on the validation set and test set. \n",
|
| 106 |
+
"\n",
|
| 107 |
+
"- The output should be saved as **`submission.npz`**. This must be a valid `npz` file containing two arrays `pred_a` and `pred_b`, each with shape `100x1x180x320` (The evaluation script will also accept predictions in the shape of `100x180x320`, if you decide to squeeze the channel dimension).\n",
|
| 108 |
+
"\n",
|
| 109 |
+
" **Any result that does not meet the specified size will be considered invalid, resulting in an assessment score of zero.**\n",
|
| 110 |
+
" \n",
|
| 111 |
+
"- Each element of the density map should be **no less than zero**, otherwise will result in an assessment score of zero.\n",
|
| 112 |
+
"\n",
|
| 113 |
+
"## **5. Scoring**\n",
|
| 114 |
+
"\n",
|
| 115 |
+
"You will be scored based on the mean relative error of your model. Relative error is defined by:\n",
|
| 116 |
+
"\n",
|
| 117 |
+
"$$\n",
|
| 118 |
+
"\\text{Relative Error} = \\frac{|y_i - \\hat{y}_i|}{|y_i|}\n",
|
| 119 |
+
"$$\n",
|
| 120 |
+
"\n",
|
| 121 |
+
"where $y_i$ is the true total density for the $i$-th sample, and $\\hat{y}_i$ is the predicted total density for the $i$-th sample.\n",
|
| 122 |
+
"\n",
|
| 123 |
+
"Your final score before normalization will be calculated based on your mean relative error, as follows:\n",
|
| 124 |
+
"\n",
|
| 125 |
+
"$$\n",
|
| 126 |
+
"\\text{Score} = \\exp(-\\frac{1}{n} \\sum_{i=1}^{n} \\frac{|y_i - \\hat{y}_i|}{y_i})\n",
|
| 127 |
+
"$$\n",
|
| 128 |
+
"\n",
|
| 129 |
+
"## **6. Baseline & Training Set**\n",
|
| 130 |
+
"\n",
|
| 131 |
+
"- Below you can find the baseline solution.\n",
|
| 132 |
+
"- The dataset is in `training_set` folder.\n",
|
| 133 |
+
"- The highest score by the Scientific Committee for this task is 0.89, this score is used for score unification.\n",
|
| 134 |
+
"- The baseline score by the Scientific Committee for this task is 0.71, this score is used for score unification."
|
| 135 |
+
]
|
| 136 |
+
},
|
| 137 |
+
{
|
| 138 |
+
"cell_type": "markdown",
|
| 139 |
+
"metadata": {},
|
| 140 |
+
"source": [
|
| 141 |
+
"### Imports"
|
| 142 |
+
]
|
| 143 |
+
},
|
| 144 |
+
{
|
| 145 |
+
"cell_type": "code",
|
| 146 |
+
"execution_count": null,
|
| 147 |
+
"metadata": {},
|
| 148 |
+
"outputs": [],
|
| 149 |
+
"source": [
|
| 150 |
+
"import random\n",
|
| 151 |
+
"import numpy as np\n",
|
| 152 |
+
"import torch\n",
|
| 153 |
+
"\n",
|
| 154 |
+
"seed = 42\n",
|
| 155 |
+
"\n",
|
| 156 |
+
"random.seed(seed) # Python built-in random\n",
|
| 157 |
+
"np.random.seed(seed) # NumPy\n",
|
| 158 |
+
"torch.manual_seed(seed) # PyTorch (CPU)\n",
|
| 159 |
+
"torch.cuda.manual_seed(seed) # PyTorch (single GPU)\n",
|
| 160 |
+
"torch.cuda.manual_seed_all(seed) # PyTorch (all GPUs)\n",
|
| 161 |
+
"\n",
|
| 162 |
+
"# Ensures deterministic behavior\n",
|
| 163 |
+
"torch.backends.cudnn.deterministic = True\n",
|
| 164 |
+
"torch.backends.cudnn.benchmark = False"
|
| 165 |
+
]
|
| 166 |
+
},
|
| 167 |
+
{
|
| 168 |
+
"cell_type": "code",
|
| 169 |
+
"execution_count": null,
|
| 170 |
+
"metadata": {},
|
| 171 |
+
"outputs": [],
|
| 172 |
+
"source": [
|
| 173 |
+
"import os\n",
|
| 174 |
+
"import torch\n",
|
| 175 |
+
"import torch.nn as nn\n",
|
| 176 |
+
"import torch.nn.functional as F\n",
|
| 177 |
+
"import torch.optim as optim\n",
|
| 178 |
+
"from torch.utils.data import DataLoader\n",
|
| 179 |
+
"from datasets import load_from_disk\n",
|
| 180 |
+
"import logging\n",
|
| 181 |
+
"from torchvision import transforms\n",
|
| 182 |
+
"from tqdm import tqdm\n",
|
| 183 |
+
"import numpy as np\n",
|
| 184 |
+
"import math\n",
|
| 185 |
+
"\n",
|
| 186 |
+
"#Contestants should mount \"counting_problem_train(v1)\" datasets while creating the node.\n",
|
| 187 |
+
"TRAIN_PATH = \"/bohr/train-adnz/v1/\" #Address of the training set and base.pth\n",
|
| 188 |
+
"# The training set is deployed automatically in the testing machine. \n",
|
| 189 |
+
"# You notebook can access the TRAIN_PATH even if you do not mount it along with notebook.\n",
|
| 190 |
+
"TRAINING_SET = TRAIN_PATH + \"train\" #Address of the traninig set \n",
|
| 191 |
+
"BASE_MODEL_PATH = TRAIN_PATH + \"base.pth\"#Address of the .pth file\n",
|
| 192 |
+
"DTYPE = torch.float32\n",
|
| 193 |
+
"DEVICE = torch.device(\"cuda:0\" if torch.cuda.is_available() else \"cpu\")\n",
|
| 194 |
+
"scale = 100.0"
|
| 195 |
+
]
|
| 196 |
+
},
|
| 197 |
+
{
|
| 198 |
+
"cell_type": "markdown",
|
| 199 |
+
"metadata": {},
|
| 200 |
+
"source": [
|
| 201 |
+
"### Logging Utilities"
|
| 202 |
+
]
|
| 203 |
+
},
|
| 204 |
+
{
|
| 205 |
+
"cell_type": "code",
|
| 206 |
+
"execution_count": null,
|
| 207 |
+
"metadata": {},
|
| 208 |
+
"outputs": [],
|
| 209 |
+
"source": [
|
| 210 |
+
"def logging_level(level='info'):\n",
|
| 211 |
+
" str_format = '%(asctime)s - %(levelname)s: %(message)s'\n",
|
| 212 |
+
" if level == 'debug':\n",
|
| 213 |
+
" logging.basicConfig(level=logging.DEBUG, format=str_format, datefmt='%Y-%m-%d %H:%M:%S')\n",
|
| 214 |
+
" elif level == 'info':\n",
|
| 215 |
+
" logging.basicConfig(level=logging.INFO, format=str_format, datefmt='%Y-%m-%d %H:%M:%S')\n",
|
| 216 |
+
" return logging\n",
|
| 217 |
+
"\n",
|
| 218 |
+
"\n",
|
| 219 |
+
"class BatchLossLogger:\n",
|
| 220 |
+
" def __init__(self, log_interval=100):\n",
|
| 221 |
+
" self.losses = []\n",
|
| 222 |
+
" self.batch_number = 0\n",
|
| 223 |
+
" self.log_interval = log_interval\n",
|
| 224 |
+
"\n",
|
| 225 |
+
" def log(self, loss):\n",
|
| 226 |
+
" self.losses.append(loss)\n",
|
| 227 |
+
" self.batch_number += 1\n",
|
| 228 |
+
" if self.batch_number % self.log_interval == 0:\n",
|
| 229 |
+
" logging.info(f'Batch No. {self.batch_number:7d} - loss: {loss:.6f}')"
|
| 230 |
+
]
|
| 231 |
+
},
|
| 232 |
+
{
|
| 233 |
+
"cell_type": "markdown",
|
| 234 |
+
"metadata": {},
|
| 235 |
+
"source": [
|
| 236 |
+
"### Training Your Model\n",
|
| 237 |
+
"#### Model Definition\n",
|
| 238 |
+
"Pretrained weights of the `FeatureExtraction` model is provided in `base.pth` in the training set, along with a function to load them.\n",
|
| 239 |
+
"`ChickenCounting` is the completed model."
|
| 240 |
+
]
|
| 241 |
+
},
|
| 242 |
+
{
|
| 243 |
+
"cell_type": "code",
|
| 244 |
+
"execution_count": null,
|
| 245 |
+
"metadata": {},
|
| 246 |
+
"outputs": [],
|
| 247 |
+
"source": [
|
| 248 |
+
"class FeatureExtraction(nn.Module):\n",
|
| 249 |
+
" def __init__(self, in_channels=3):\n",
|
| 250 |
+
" super(FeatureExtraction, self).__init__()\n",
|
| 251 |
+
" self.conv1 = nn.Conv2d(in_channels, 64, kernel_size=3, padding=2, dilation=2)\n",
|
| 252 |
+
" self.conv2 = nn.Conv2d(64, 64, kernel_size=3, padding=2, dilation=2)\n",
|
| 253 |
+
" self.pool2 = nn.MaxPool2d(kernel_size=2, stride=2, padding=0)\n",
|
| 254 |
+
" self.conv3 = nn.Conv2d(64, 128, kernel_size=3, padding=2, dilation=2)\n",
|
| 255 |
+
" self.conv4 = nn.Conv2d(128, 128, kernel_size=3, padding=2, dilation=2)\n",
|
| 256 |
+
" self.pool4 = nn.MaxPool2d(kernel_size=2, stride=2, padding=0)\n",
|
| 257 |
+
"\n",
|
| 258 |
+
"\n",
|
| 259 |
+
" def forward(self, x):\n",
|
| 260 |
+
" x = F.relu(self.conv1(x))\n",
|
| 261 |
+
" x = F.relu(self.conv2(x))\n",
|
| 262 |
+
" x = self.pool2(x)\n",
|
| 263 |
+
" x = F.relu(self.conv3(x))\n",
|
| 264 |
+
" x = F.relu(self.conv4(x))\n",
|
| 265 |
+
" x = self.pool4(x)\n",
|
| 266 |
+
"\n",
|
| 267 |
+
" return x\n",
|
| 268 |
+
"\n",
|
| 269 |
+
" def load_pretrained_weights_partial(self, weights_path, num_layers=4):\n",
|
| 270 |
+
" save_model = torch.load(weights_path)\n",
|
| 271 |
+
" partial_state_dict = {}\n",
|
| 272 |
+
" expected_layers = [\n",
|
| 273 |
+
" 'feature_extraction.conv1.weight', 'feature_extraction.conv1.bias',\n",
|
| 274 |
+
" 'feature_extraction.conv2.weight', 'feature_extraction.conv2.bias',\n",
|
| 275 |
+
" 'feature_extraction.conv3.weight', 'feature_extraction.conv3.bias',\n",
|
| 276 |
+
" 'feature_extraction.conv4.weight', 'feature_extraction.conv4.bias',\n",
|
| 277 |
+
" ]\n",
|
| 278 |
+
" state_dict = {k.split('.', 1)[-1]: v for k, v in save_model.items() if k in expected_layers[:2 * num_layers]}\n",
|
| 279 |
+
" model_dict = self.state_dict()\n",
|
| 280 |
+
"\n",
|
| 281 |
+
" for k in state_dict:\n",
|
| 282 |
+
" if k in model_dict:\n",
|
| 283 |
+
" partial_state_dict[k] = state_dict[k]\n",
|
| 284 |
+
" print(k)\n",
|
| 285 |
+
"\n",
|
| 286 |
+
" self.load_state_dict(partial_state_dict)\n",
|
| 287 |
+
"\n",
|
| 288 |
+
"\n",
|
| 289 |
+
"class DensityDecoder(nn.Module): # Define your decoder model here.\n",
|
| 290 |
+
" def __init__(self):\n",
|
| 291 |
+
" super(DensityDecoder, self).__init__()\n",
|
| 292 |
+
" self.conv5 = nn.Conv2d(in_channels=128, out_channels=1, kernel_size=3, padding=2, dilation=2)\n",
|
| 293 |
+
"\n",
|
| 294 |
+
" def forward(self, x):\n",
|
| 295 |
+
" x = F.relu(self.conv5(x))\n",
|
| 296 |
+
" return x\n",
|
| 297 |
+
"\n",
|
| 298 |
+
"\n",
|
| 299 |
+
"class ChickenCounting(nn.Module):\n",
|
| 300 |
+
" def __init__(self):\n",
|
| 301 |
+
" super(ChickenCounting, self).__init__()\n",
|
| 302 |
+
" self.feature_extraction = FeatureExtraction()\n",
|
| 303 |
+
" self.feature_decoder = DensityDecoder()\n",
|
| 304 |
+
"\n",
|
| 305 |
+
" def forward(self, x):\n",
|
| 306 |
+
" x = self.feature_extraction(x)\n",
|
| 307 |
+
" x = self.feature_decoder(x)\n",
|
| 308 |
+
" return x"
|
| 309 |
+
]
|
| 310 |
+
},
|
| 311 |
+
{
|
| 312 |
+
"cell_type": "markdown",
|
| 313 |
+
"metadata": {},
|
| 314 |
+
"source": [
|
| 315 |
+
"### Reading the Dataset\n",
|
| 316 |
+
"Read the train dataset"
|
| 317 |
+
]
|
| 318 |
+
},
|
| 319 |
+
{
|
| 320 |
+
"cell_type": "code",
|
| 321 |
+
"execution_count": null,
|
| 322 |
+
"metadata": {},
|
| 323 |
+
"outputs": [],
|
| 324 |
+
"source": [
|
| 325 |
+
"train_dataset = load_from_disk(TRAINING_SET)\n",
|
| 326 |
+
"\n",
|
| 327 |
+
"image_transform = transforms.Compose([\n",
|
| 328 |
+
" transforms.ToTensor(),\n",
|
| 329 |
+
"])\n",
|
| 330 |
+
"\n",
|
| 331 |
+
"def collate_fn(batch, scale = scale):\n",
|
| 332 |
+
" return {\n",
|
| 333 |
+
" \"image\": torch.stack([image_transform(item[\"image\"]) for item in batch]),\n",
|
| 334 |
+
" \"density\": torch.stack([torch.tensor(item[\"density\"], dtype=DTYPE).unsqueeze(0) * scale for item in batch]) # Multiply by scale for faster training\n",
|
| 335 |
+
" }\n",
|
| 336 |
+
"\n",
|
| 337 |
+
"train_loader = DataLoader(train_dataset, batch_size=8, shuffle=True, collate_fn=collate_fn)\n",
|
| 338 |
+
"val_loader = DataLoader(train_dataset, batch_size=1, shuffle=False, collate_fn=collate_fn)"
|
| 339 |
+
]
|
| 340 |
+
},
|
| 341 |
+
{
|
| 342 |
+
"cell_type": "markdown",
|
| 343 |
+
"metadata": {},
|
| 344 |
+
"source": [
|
| 345 |
+
"### Run Training"
|
| 346 |
+
]
|
| 347 |
+
},
|
| 348 |
+
{
|
| 349 |
+
"cell_type": "code",
|
| 350 |
+
"execution_count": null,
|
| 351 |
+
"metadata": {},
|
| 352 |
+
"outputs": [],
|
| 353 |
+
"source": [
|
| 354 |
+
"#Definition of the training process\n",
|
| 355 |
+
"def train_chickenfcn(model, train_loader, val_loader, optimizer, scheduler, num_epochs, device, save_path):\n",
|
| 356 |
+
" model.train()\n",
|
| 357 |
+
" criterion_mse = torch.nn.MSELoss(reduction='sum').to(device)\n",
|
| 358 |
+
" criterion_mae = torch.nn.L1Loss(reduction='sum').to(device)\n",
|
| 359 |
+
" best_loss = float('inf')\n",
|
| 360 |
+
" print(train_loader.__len__())\n",
|
| 361 |
+
"\n",
|
| 362 |
+
" for epoch in range(num_epochs):\n",
|
| 363 |
+
" train_loss_mse = 0.0\n",
|
| 364 |
+
" train_loss_mae = 0.0\n",
|
| 365 |
+
"\n",
|
| 366 |
+
" train_loader_tqdm = tqdm(train_loader, desc=f'Epoch {epoch + 1}/{num_epochs}', leave=False)\n",
|
| 367 |
+
"\n",
|
| 368 |
+
" for i, data in enumerate(train_loader_tqdm, 0):\n",
|
| 369 |
+
" inputs, targets = data[\"image\"], data[\"density\"]\n",
|
| 370 |
+
" inputs = inputs.to(device).float()\n",
|
| 371 |
+
" targets = targets.to(device).float()\n",
|
| 372 |
+
" # print(targets.shape)\n",
|
| 373 |
+
" # t = np.sum((targets[0] / scale).cpu().numpy().squeeze())\n",
|
| 374 |
+
" # print(t)\n",
|
| 375 |
+
"\n",
|
| 376 |
+
" optimizer.zero_grad()\n",
|
| 377 |
+
" \n",
|
| 378 |
+
" outputs = model(inputs)\n",
|
| 379 |
+
" \n",
|
| 380 |
+
" loss_mse = criterion_mse(outputs, targets)\n",
|
| 381 |
+
" loss_mae = criterion_mae(outputs, targets)\n",
|
| 382 |
+
" loss_mae.backward()\n",
|
| 383 |
+
"\n",
|
| 384 |
+
" torch.nn.utils.clip_grad_norm_(model.parameters(), max_norm=2.0)\n",
|
| 385 |
+
"\n",
|
| 386 |
+
" optimizer.step()\n",
|
| 387 |
+
" train_loss_mse += loss_mse.item()\n",
|
| 388 |
+
" train_loss_mae += loss_mae.item()\n",
|
| 389 |
+
"\n",
|
| 390 |
+
" train_loader_tqdm.set_postfix({'Train MSE Loss': loss_mse.item(), 'Train MAE Loss': loss_mae.item()})\n",
|
| 391 |
+
"\n",
|
| 392 |
+
" train_loss_mse /= (len(train_loader))\n",
|
| 393 |
+
" train_loss_mae /= (len(train_loader))\n",
|
| 394 |
+
" logging.info(\n",
|
| 395 |
+
" f'Epoch [{epoch + 1}/{num_epochs}], Train MSE loss: {train_loss_mse:.8f}, MAE loss: {train_loss_mae:.8f}')\n",
|
| 396 |
+
"\n",
|
| 397 |
+
" scheduler.step()\n",
|
| 398 |
+
"\n",
|
| 399 |
+
" # Validation\n",
|
| 400 |
+
" model.eval()\n",
|
| 401 |
+
" val_loss_mse = 0.0\n",
|
| 402 |
+
" val_loss_mae = 0.0\n",
|
| 403 |
+
"\n",
|
| 404 |
+
" val_loader_tqdm = tqdm(val_loader, desc=f'Validation Epoch {epoch + 1}/{num_epochs}', leave=False)\n",
|
| 405 |
+
"\n",
|
| 406 |
+
" with torch.no_grad():\n",
|
| 407 |
+
" for i, data in enumerate(val_loader_tqdm, 0):\n",
|
| 408 |
+
" inputs, targets = data[\"image\"], data[\"density\"]\n",
|
| 409 |
+
" inputs = inputs.to(device).float()\n",
|
| 410 |
+
" targets = targets.to(device).float()\n",
|
| 411 |
+
"\n",
|
| 412 |
+
" outputs = model(inputs)\n",
|
| 413 |
+
" mse_loss = criterion_mse(outputs, targets)\n",
|
| 414 |
+
" mae_loss = criterion_mae(outputs, targets)\n",
|
| 415 |
+
" val_loss_mse += mse_loss.item()\n",
|
| 416 |
+
" val_loss_mae += mae_loss.item()\n",
|
| 417 |
+
"\n",
|
| 418 |
+
" val_loader_tqdm.set_postfix(\n",
|
| 419 |
+
" {'Validation MSE Loss': mse_loss.item(), 'Validation MAE Loss': mae_loss.item()})\n",
|
| 420 |
+
"\n",
|
| 421 |
+
" val_loss_mse /= (len(val_loader))\n",
|
| 422 |
+
" val_loss_mae /= (len(val_loader))\n",
|
| 423 |
+
" logging.info(\n",
|
| 424 |
+
" f'Epoch [{epoch + 1}/{num_epochs}], Validation MSE Loss: {val_loss_mse:.8f}, MAE Loss: {val_loss_mae:.8f}')\n",
|
| 425 |
+
"\n",
|
| 426 |
+
" # Save Model\n",
|
| 427 |
+
" if val_loss_mae < best_loss:\n",
|
| 428 |
+
" best_loss = val_loss_mae\n",
|
| 429 |
+
" torch.save(model.state_dict(), save_path)\n",
|
| 430 |
+
"\n",
|
| 431 |
+
" print('Finished Training ChickenFCN')"
|
| 432 |
+
]
|
| 433 |
+
},
|
| 434 |
+
{
|
| 435 |
+
"cell_type": "code",
|
| 436 |
+
"execution_count": null,
|
| 437 |
+
"metadata": {},
|
| 438 |
+
"outputs": [],
|
| 439 |
+
"source": [
|
| 440 |
+
"logging = logging_level('info')\n",
|
| 441 |
+
"logging.debug('use debug level logging setting')\n",
|
| 442 |
+
"\n",
|
| 443 |
+
"################################################################################\n",
|
| 444 |
+
"# Experiment Settings\n",
|
| 445 |
+
"################################################################################\n",
|
| 446 |
+
"learning_rate = 1e-4\n",
|
| 447 |
+
"lr_decay = 1e-5\n",
|
| 448 |
+
"weight_decay = 0.0001\n",
|
| 449 |
+
"save_path = \"model.pth\"\n",
|
| 450 |
+
"\n",
|
| 451 |
+
"epochs = 20\n",
|
| 452 |
+
"\n",
|
| 453 |
+
"# Training\n",
|
| 454 |
+
"model = ChickenCounting().to(DEVICE)\n",
|
| 455 |
+
"model.feature_extraction.load_pretrained_weights_partial(BASE_MODEL_PATH)\n",
|
| 456 |
+
"print('load model success')\n",
|
| 457 |
+
"\n",
|
| 458 |
+
"optimizer = optim.Adam(model.parameters(), lr=learning_rate, weight_decay=weight_decay)\n",
|
| 459 |
+
"scheduler = optim.lr_scheduler.StepLR(optimizer, step_size=1, gamma=1 - lr_decay)\n",
|
| 460 |
+
"\n",
|
| 461 |
+
"logging.info('Begin training single view model...')\n",
|
| 462 |
+
"train_chickenfcn(model, train_loader, val_loader, optimizer, scheduler, epochs, DEVICE, save_path=save_path)\n",
|
| 463 |
+
"logging.info('Finished training single view model.')"
|
| 464 |
+
]
|
| 465 |
+
},
|
| 466 |
+
{
|
| 467 |
+
"cell_type": "markdown",
|
| 468 |
+
"metadata": {},
|
| 469 |
+
"source": [
|
| 470 |
+
"### Evaluate Model\n",
|
| 471 |
+
"This section validates the model on the train set, which helps contestants understand whether the model is usable and calculate the score on the train set."
|
| 472 |
+
]
|
| 473 |
+
},
|
| 474 |
+
{
|
| 475 |
+
"cell_type": "code",
|
| 476 |
+
"execution_count": null,
|
| 477 |
+
"metadata": {},
|
| 478 |
+
"outputs": [],
|
| 479 |
+
"source": [
|
| 480 |
+
"# Definition of the evaluation function\n",
|
| 481 |
+
"def evaluate(model, val_loader, device, scale): # Function used for final scoring.\n",
|
| 482 |
+
" model.eval() # Set the model to evaluation mode\n",
|
| 483 |
+
"\n",
|
| 484 |
+
" # Initialize metrics\n",
|
| 485 |
+
" mse = 0.0\n",
|
| 486 |
+
" mae = 0.0\n",
|
| 487 |
+
" predict_num = 0.0\n",
|
| 488 |
+
" true_num = 0.0\n",
|
| 489 |
+
" rate = 0.0\n",
|
| 490 |
+
"\n",
|
| 491 |
+
" with torch.no_grad(): # Disable gradient calculation for inference\n",
|
| 492 |
+
" for i, data in enumerate(val_loader, 0):\n",
|
| 493 |
+
" inputs, targets = data[\"image\"], data[\"density\"]\n",
|
| 494 |
+
" inputs = inputs.to(device).float() # Move inputs to device and convert to float\n",
|
| 495 |
+
" targets = targets.to(device).float() # Move targets to device and convert to float\n",
|
| 496 |
+
"\n",
|
| 497 |
+
" # Get the model predictions\n",
|
| 498 |
+
" outputs = model(inputs) / scale # Adjusting for the scaling factor\n",
|
| 499 |
+
"\n",
|
| 500 |
+
" # Convert tensors to numpy for visualization and metrics calculation\n",
|
| 501 |
+
" inputs_np = inputs.cpu().numpy() # Convert inputs to numpy\n",
|
| 502 |
+
" targets_np = targets.cpu().numpy() # Convert targets to numpy\n",
|
| 503 |
+
" outputs_np = outputs.cpu().numpy() # Convert outputs to numpy\n",
|
| 504 |
+
" # imshow_res(inputs_np, targets_np, outputs_np, scale) # Uncomment to visualize results\n",
|
| 505 |
+
"\n",
|
| 506 |
+
" # Calculate true and predicted sums for comparison\n",
|
| 507 |
+
" t = np.sum((targets[0] / scale).cpu().numpy().squeeze()) # Ground truth sum\n",
|
| 508 |
+
" g = np.sum(outputs.cpu().numpy().squeeze()) # Predicted sum\n",
|
| 509 |
+
" print(f'NO.{i} true_sum={t}, get_sum={g}, abs={abs(t - g)}, rate={abs(1 - g / t)}')\n",
|
| 510 |
+
"\n",
|
| 511 |
+
" # Update metrics\n",
|
| 512 |
+
" predict_num += g\n",
|
| 513 |
+
" true_num += t\n",
|
| 514 |
+
" rate += abs(1 - g / t)\n",
|
| 515 |
+
" mae += abs(t - g)\n",
|
| 516 |
+
" mse += abs(t - g) * abs(t - g)\n",
|
| 517 |
+
"\n",
|
| 518 |
+
" # Calculate average metrics across all batches\n",
|
| 519 |
+
" mae /= len(val_loader)\n",
|
| 520 |
+
" mse /= len(val_loader)\n",
|
| 521 |
+
" predict_num /= len(val_loader)\n",
|
| 522 |
+
" true_num /= len(val_loader)\n",
|
| 523 |
+
" rate /= len(val_loader)\n",
|
| 524 |
+
"\n",
|
| 525 |
+
" # Log the results\n",
|
| 526 |
+
" logging.info(\n",
|
| 527 |
+
" f'test ---- Score: {math.exp(-rate):.3f}, MSE: {mse:.4f}, MAE: {mae:.4f}, Chicken_avg: {predict_num:.4f}')\n",
|
| 528 |
+
" return math.exp(-rate)"
|
| 529 |
+
]
|
| 530 |
+
},
|
| 531 |
+
{
|
| 532 |
+
"cell_type": "code",
|
| 533 |
+
"execution_count": null,
|
| 534 |
+
"metadata": {},
|
| 535 |
+
"outputs": [],
|
| 536 |
+
"source": [
|
| 537 |
+
"model.load_state_dict(torch.load(save_path, map_location=DEVICE))\n",
|
| 538 |
+
"model.to(DEVICE)\n",
|
| 539 |
+
"evaluate(model, val_loader, DEVICE, scale)"
|
| 540 |
+
]
|
| 541 |
+
},
|
| 542 |
+
{
|
| 543 |
+
"cell_type": "markdown",
|
| 544 |
+
"metadata": {},
|
| 545 |
+
"source": [
|
| 546 |
+
"### Submission\n",
|
| 547 |
+
"This part is to generate the result files for testing and scoring.\n",
|
| 548 |
+
"Contestants couldn't access the validation set(test_a) and the test set(test_b) locally.\n",
|
| 549 |
+
"Please read through the following code carefully. Make sure to following the file naming conventions."
|
| 550 |
+
]
|
| 551 |
+
},
|
| 552 |
+
{
|
| 553 |
+
"cell_type": "code",
|
| 554 |
+
"execution_count": null,
|
| 555 |
+
"metadata": {},
|
| 556 |
+
"outputs": [],
|
| 557 |
+
"source": [
|
| 558 |
+
"#DATA_PATH is the secret environment variable to point the address of the validation set and test set on the testing machine. \n",
|
| 559 |
+
"#Contestants cannot access this address locally.\n",
|
| 560 |
+
"if os.environ.get('DATA_PATH'): \n",
|
| 561 |
+
" DATA_PATH = os.environ.get(\"DATA_PATH\") + \"/\" \n",
|
| 562 |
+
"else:\n",
|
| 563 |
+
" DATA_PATH = \"\" # Fallback for local testing\n",
|
| 564 |
+
"def collate_fn(batch): # The test datasets will not provide target densities\n",
|
| 565 |
+
" return torch.stack([image_transform(item[\"image\"]) for item in batch])\n",
|
| 566 |
+
"\n",
|
| 567 |
+
"test_dataset = load_from_disk(os.path.join(DATA_PATH, \"test_a\"))\n",
|
| 568 |
+
"test_loader = DataLoader(test_dataset, batch_size=16, shuffle=False, collate_fn=collate_fn)\n",
|
| 569 |
+
"\n",
|
| 570 |
+
"predictions = []\n",
|
| 571 |
+
"model.eval()\n",
|
| 572 |
+
"with torch.no_grad():\n",
|
| 573 |
+
" for batch in tqdm(test_loader):\n",
|
| 574 |
+
" outputs = model(batch.to(DEVICE)) / scale\n",
|
| 575 |
+
" predictions.append(outputs.cpu().numpy())\n",
|
| 576 |
+
"\n",
|
| 577 |
+
"pred_a = np.concatenate(predictions, axis=0)\n",
|
| 578 |
+
"\n",
|
| 579 |
+
"del test_dataset\n",
|
| 580 |
+
"del test_loader\n",
|
| 581 |
+
"del predictions\n",
|
| 582 |
+
"\n",
|
| 583 |
+
"test_dataset = load_from_disk(os.path.join(DATA_PATH, \"test_b\"))\n",
|
| 584 |
+
"test_loader = DataLoader(test_dataset, batch_size=16, shuffle=False, collate_fn=collate_fn)\n",
|
| 585 |
+
"\n",
|
| 586 |
+
"predictions = []\n",
|
| 587 |
+
"with torch.no_grad():\n",
|
| 588 |
+
" for batch in tqdm(test_loader):\n",
|
| 589 |
+
" outputs = model(batch.to(DEVICE)) / scale\n",
|
| 590 |
+
" predictions.append(outputs.cpu().numpy())\n",
|
| 591 |
+
"\n",
|
| 592 |
+
"pred_b = np.concatenate(predictions, axis=0)\n",
|
| 593 |
+
"\n",
|
| 594 |
+
"np.savez('submission.npz', pred_a=pred_a, pred_b=pred_b) # save your submissions in `submission.npz` file with the keys `pred_a` and `pred_b`"
|
| 595 |
+
]
|
| 596 |
+
}
|
| 597 |
+
],
|
| 598 |
+
"metadata": {
|
| 599 |
+
"kernelspec": {
|
| 600 |
+
"display_name": "Python 3 (ipykernel)",
|
| 601 |
+
"language": "python",
|
| 602 |
+
"name": "python3"
|
| 603 |
+
},
|
| 604 |
+
"language_info": {
|
| 605 |
+
"codemirror_mode": {
|
| 606 |
+
"name": "ipython",
|
| 607 |
+
"version": 3
|
| 608 |
+
},
|
| 609 |
+
"file_extension": ".py",
|
| 610 |
+
"mimetype": "text/x-python",
|
| 611 |
+
"name": "python",
|
| 612 |
+
"nbconvert_exporter": "python",
|
| 613 |
+
"pygments_lexer": "ipython3",
|
| 614 |
+
"version": "3.12.9"
|
| 615 |
+
}
|
| 616 |
+
},
|
| 617 |
+
"nbformat": 4,
|
| 618 |
+
"nbformat_minor": 4
|
| 619 |
+
}
|
benchmark/IOAI/IOAI2025/Individual-Contest/Concepts/Concepts.ipynb
ADDED
|
@@ -0,0 +1,826 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"id": "097ce009-a7a8-45c7-90f4-dd6f8bbb8228",
|
| 6 |
+
"metadata": {},
|
| 7 |
+
"source": [
|
| 8 |
+
"<img src=\"./figs/IOAI-Logo.png\" alt=\"IOAI Logo\" width=\"200\" height=\"auto\">\n",
|
| 9 |
+
"\n",
|
| 10 |
+
"[IOAI 2025 (Beijing, China), Individual Contest](https://ioai-official.org/china-2025)\n",
|
| 11 |
+
"\n",
|
| 12 |
+
"[](https://colab.research.google.com/github/IOAI-official/IOAI-2025/blob/main/Individual-Contest/Concepts/Concepts.ipynb)"
|
| 13 |
+
]
|
| 14 |
+
},
|
| 15 |
+
{
|
| 16 |
+
"cell_type": "markdown",
|
| 17 |
+
"id": "3ddf717a-91f1-4237-8fb2-5d94371f2e4a",
|
| 18 |
+
"metadata": {
|
| 19 |
+
"jp-MarkdownHeadingCollapsed": true
|
| 20 |
+
},
|
| 21 |
+
"source": [
|
| 22 |
+
"# Concepts\n",
|
| 23 |
+
"\n",
|
| 24 |
+
"## **1. Problem Description**\n",
|
| 25 |
+
"\n",
|
| 26 |
+
"**Concepts** is a word-guessing game where players communicate ideas through visual icons. There are two roles: the **Clue-Giver** and the **Guesser**. A shared set of visual icons, each with a known description, is available to both players. Here are some sample icons:\n",
|
| 27 |
+
"\n",
|
| 28 |
+
"<img src=\"./figs/Concepts Fig 1.png\" width=\"300\">\n",
|
| 29 |
+
"\n",
|
| 30 |
+
"The Clue-Giver first selects a **secret**, which is a word or phrase, and then provides a **hint** about it by pointing to an **ordered sequence** of icons from the shared set — speaking or writing is not allowed.\n",
|
| 31 |
+
"\n",
|
| 32 |
+
"The order of the icons in the hint is meaningful:\n",
|
| 33 |
+
"\n",
|
| 34 |
+
"- The **first icon** typically represents the core idea of the secret.\n",
|
| 35 |
+
"- The **subsequent icons** provide supporting context that helps clarify or elaborate on the main concept.\n",
|
| 36 |
+
"\n",
|
| 37 |
+
"### Example 1\n",
|
| 38 |
+
"\n",
|
| 39 |
+
"The following hint might be interpreted as *a place where a job that fights fire takes place* — in other words, a **fire station**:\n",
|
| 40 |
+
"\n",
|
| 41 |
+
"<img src=\"./figs/Concepts Fig 2.png\" width=\"300\">\n",
|
| 42 |
+
"\n",
|
| 43 |
+
"If the icon order is reversed, it could instead suggest *a job that fights fire in a house* — pointing to a **firefighter**:\n",
|
| 44 |
+
"\n",
|
| 45 |
+
"<img src=\"./figs/Concepts Fig 3.png\" width=\"300\">\n",
|
| 46 |
+
"\n",
|
| 47 |
+
"### Example 2\n",
|
| 48 |
+
"\n",
|
| 49 |
+
"Icons can take on different meanings depending on their context. For example, the heart icon can appear in the following hint, which suggests *a tool used by doctors to listen to the heart* — a **stethoscope**:\n",
|
| 50 |
+
"\n",
|
| 51 |
+
"<img src=\"./figs/Concepts Fig 4.png\" width=\"300\">\n",
|
| 52 |
+
"\n",
|
| 53 |
+
"The same heart icon might instead appear in a hint that implies *a fictional character that is both dead and alive* — pointing to a **zombie**:\n",
|
| 54 |
+
"\n",
|
| 55 |
+
"<img src=\"./figs/Concepts Fig 5.png\" width=\"300\">\n",
|
| 56 |
+
"\n",
|
| 57 |
+
"At Home-Stage, contestants had developed an AI program that predicts outcomes based on a sequence of hints. It's fun. However, your friend has now challenged you: \n",
|
| 58 |
+
"*\"Guessing is easy, but can you make an AI system that can give a good clue as well?\"*\n",
|
| 59 |
+
"\n",
|
| 60 |
+
"In fact, they further challenged you to see if you can make an AI system that can provide a good clue so that another AI system can guess your keyword!\n",
|
| 61 |
+
"\n",
|
| 62 |
+
"To make the challenge more interesting, we now play the typical Concept game. To recall, our previous Concept game was simplified so that a clue could only consist of a single sequence of markers.\n",
|
| 63 |
+
"\n",
|
| 64 |
+
"Now, you may provide up to **4 sequences of markers**!\n",
|
| 65 |
+
"\n",
|
| 66 |
+
"With this, we can express complex ideas better. Considering the following that utilizes 3 sequences of markers to explain a **samurai**:\n",
|
| 67 |
+
"\n",
|
| 68 |
+
"<img src=\"./figs/Concepts Fig 6.png\" width=\"300\">\n",
|
| 69 |
+
"\n",
|
| 70 |
+
"But wait, there's more. To make the challenge even more interesting, the game will now include some keywords that are not typically present in a Concept game, such as \"International Olympiad.\"\n",
|
| 71 |
+
"\n",
|
| 72 |
+
"Are you up to the challenge?\n",
|
| 73 |
+
"\n",
|
| 74 |
+
"<img src=\"./figs/Concepts Fig 7.png\" width=\"600\">\n",
|
| 75 |
+
"\n",
|
| 76 |
+
"**New AI-Powered Format:**\n",
|
| 77 |
+
"We've replaced the human guesser with an **AI Guesser**. To streamline game play:\n",
|
| 78 |
+
"\n",
|
| 79 |
+
"1. The target word (*label*) will always be selected from a predefined set (`options`).\n",
|
| 80 |
+
"2. Hints must be an **ordered sequence of markers** chosen exclusively from a fixed set of **118 candidate markers**.\n",
|
| 81 |
+
"\n",
|
| 82 |
+
"**Terminologies**\n",
|
| 83 |
+
"\n",
|
| 84 |
+
"To ensure clarity and consistency, we are standardizing key terms across all materials.\n",
|
| 85 |
+
"\n",
|
| 86 |
+
"- **label**: The target answer (or \"secret\") to be identified.\n",
|
| 87 |
+
"- **options**: The predefined candidate set from which all valid *labels* are selected.\n",
|
| 88 |
+
"- **marker**: An icon representing a concept, accompanied by its text description.\n",
|
| 89 |
+
"- **hints**: An **ordered sequence** of *markers* provided to the AI guesser to help identify the *label*.\n",
|
| 90 |
+
"\n",
|
| 91 |
+
"Your task is to provide **hints** for each *label* to help the **AI guesser** identify it. For example, when the target label is `\"microphone\"`, your program may generate four hint sequences like:\n",
|
| 92 |
+
"\n",
|
| 93 |
+
"1. **Hint 1**: \n",
|
| 94 |
+
" `[\"Object-Box\", \"Electronic-Computing\", \"Mouth-Taste\", \"Ear-Sound-Hearing\", \"Tool-Construction\"]`\n",
|
| 95 |
+
"2. **Hint 2**: \n",
|
| 96 |
+
" `[\"Music-Song\", \"Television-Program-Show\", \"Work-Occupation\", \"Use - Action-Do - Verbe-Button\"]`\n",
|
| 97 |
+
"3. **Hint 3**: \n",
|
| 98 |
+
" `[\"Black\", \"Metal\", \"Plastic-Rubber\", \"Cylinder\", \"Circle-Ring\"]`\n",
|
| 99 |
+
"4. **Hint 4**: \n",
|
| 100 |
+
" `[\"Arm-Hand-Finger\", \"Happy-Positive\", \"Expression - Quote-Talking-Words\", \"Life-Heart-Love\"]`\n",
|
| 101 |
+
"\n",
|
| 102 |
+
"**Note**: The above example is for illustrative purposes only. The program should generate lists of IDs but not strings; please refer to both `3. Task` and the [baseline.ipynb](https://ioai.bohrium.com/notebooks/26681337682).\n",
|
| 103 |
+
"\n",
|
| 104 |
+
"## **2. Dataset**\n",
|
| 105 |
+
"\n",
|
| 106 |
+
"The structure of the provided dataset is as follows:\n",
|
| 107 |
+
"\n",
|
| 108 |
+
"```\n",
|
| 109 |
+
"datasets/\n",
|
| 110 |
+
"├── train/\n",
|
| 111 |
+
"│ └── A huggingface dataset\n",
|
| 112 |
+
"└── hint_descriptions/\n",
|
| 113 |
+
" └── A huggingface dataset\n",
|
| 114 |
+
"\n",
|
| 115 |
+
"\n",
|
| 116 |
+
"os.environ.get(\"DATA_PATH\")/\n",
|
| 117 |
+
"└── test/\n",
|
| 118 |
+
" ├── test_a/\n",
|
| 119 |
+
" │ └── A huggingface dataset\n",
|
| 120 |
+
" └── test_b/\n",
|
| 121 |
+
" └── A huggingface dataset\n",
|
| 122 |
+
"```\n",
|
| 123 |
+
"\n",
|
| 124 |
+
"1. Training set: files in this folder are used for model training. It contains:\n",
|
| 125 |
+
" - `train/`: A huggingface dataset with a single split `'train'`, with 30 examples, each containing:\n",
|
| 126 |
+
" - `label`: string - the target keyword/answer\n",
|
| 127 |
+
" - `options`: sequence of strings - list of 100 possible choices\n",
|
| 128 |
+
" - `hint_descriptions/`: A huggingface dataset with a single split `'train'`, with 118 markers and their descriptions:\n",
|
| 129 |
+
" - `ID`: int64 - unique identifier for each marker\n",
|
| 130 |
+
" - `Description`: string - textual description of what the marker represents\n",
|
| 131 |
+
" - `image`: Image - visual representation of the marker\n",
|
| 132 |
+
"\n",
|
| 133 |
+
"2. Test sets: Located at `os.environ.get(\"DATA_PATH\")/test/`. These will be inaccessible during development and will only be available in the evaluation environment:\n",
|
| 134 |
+
" - `test_a/`: A huggingface dataset with a single split `'test'` containing 150 examples for leaderboard A evaluation\n",
|
| 135 |
+
" - `test_b/`: A huggingface dataset with a single split `'test'` containing 150 examples for final scoring\n",
|
| 136 |
+
" Both test datasets contain the same structure as the training set (`label` and `options` fields).\n",
|
| 137 |
+
"\n",
|
| 138 |
+
"## **3. Task**\n",
|
| 139 |
+
"\n",
|
| 140 |
+
"Your task is to provide **hint** for each *label* to help the **AI guesser** identify it. You are required to develop a program that takes two inputs:\n",
|
| 141 |
+
"\n",
|
| 142 |
+
"1. A string `label` (your secret *label*)\n",
|
| 143 |
+
"2. The `options` list (100 candidate choices for the guesser)\n",
|
| 144 |
+
"\n",
|
| 145 |
+
"The `label` is guaranteed to be one of the `options`.\n",
|
| 146 |
+
"\n",
|
| 147 |
+
"Additionally, the program will utilize the predefined `candidate markers`.\n",
|
| 148 |
+
"\n",
|
| 149 |
+
"<img src=\"./figs/Concepts Fig 8.png\" width=\"600\">\n",
|
| 150 |
+
"\n",
|
| 151 |
+
"\n",
|
| 152 |
+
"This program should return a list of lists of integers for each `label`, representing the hints(i.e. the sequences of markers). Specifically:\n",
|
| 153 |
+
"\n",
|
| 154 |
+
"- The returned list must contain **no more than 4** sequences.\n",
|
| 155 |
+
"- Each sequence can contain **up to 8 integers**.\n",
|
| 156 |
+
"- Each integer represents the ID of a marker in the clue.\n",
|
| 157 |
+
"\n",
|
| 158 |
+
"Your hints will then be given to a black-box AI guesser. You will score a point if the black-box AI guesser can correctly guess your secret keyword based on your hints.\n",
|
| 159 |
+
"\n",
|
| 160 |
+
"## **4. Submission**\n",
|
| 161 |
+
"\n",
|
| 162 |
+
"Submit a notebook that generates `submission.zip`, which includes `clues_a.jsonl` and `clues_b.jsonl`, the clues for testset a and b, respectively, in `json` format. Refer to the baseline notebook for how to generate these files and the specific structure of the `jsonl` files. Please make sure to follow the naming and structuring conventions.\n",
|
| 163 |
+
"\n",
|
| 164 |
+
"Contestants may submit model files. **If submitting model files, contestants must create a corresponding dataset on the Bohrium platform.** Only **one** dataset **can** be submitted for this task, and its size **must not** exceed 2GB. Preloaded datasets and models will be automatically mounted on the test machine, **eliminating the need for manual mounting during submission.**\n",
|
| 165 |
+
"\n",
|
| 166 |
+
"Additionally, contestants are permitted to use larger external models to assist in developing their submission.\n",
|
| 167 |
+
"\n",
|
| 168 |
+
"## **5. Score**\n",
|
| 169 |
+
"\n",
|
| 170 |
+
"Your clue is evaluated using two metrics:\n",
|
| 171 |
+
"\n",
|
| 172 |
+
"### Hits@10\n",
|
| 173 |
+
"\n",
|
| 174 |
+
"= 1 if the secret word is in the top 10 guesses from the AI, else 0.\n",
|
| 175 |
+
"\n",
|
| 176 |
+
"### NDCG@10 (Normalized Discounted Cumulative Gain) \n",
|
| 177 |
+
"Rewards the correct guess more if it appears higher in the list.\n",
|
| 178 |
+
"\n",
|
| 179 |
+
"If the secret word is at rank *i* (1-based):\n",
|
| 180 |
+
"\n",
|
| 181 |
+
"$$\n",
|
| 182 |
+
"\\text{NDCG@10} = \\frac{1}{\\log_2(i + 1)}\n",
|
| 183 |
+
"$$\n",
|
| 184 |
+
"\n",
|
| 185 |
+
"**Examples:**\n",
|
| 186 |
+
"- Rank 1 → 1.00 \n",
|
| 187 |
+
"- Rank 2 → ~0.63 \n",
|
| 188 |
+
"- Rank 4 → ~0.43 \n",
|
| 189 |
+
"- Rank 10 → ~0.29\n",
|
| 190 |
+
"\n",
|
| 191 |
+
"### Final Score\n",
|
| 192 |
+
"\n",
|
| 193 |
+
"Your final score will be a combination of both, specifically, it will be 0.9 Hits@10 + 0.1 NDCG@10.\n",
|
| 194 |
+
"\n",
|
| 195 |
+
"The scoring means that you'll get a significant point as long as the guesser can guess the secret keyword correctly, but more point is given if the guesser can predict the secret keyword earlier.\n",
|
| 196 |
+
"\n",
|
| 197 |
+
"\n",
|
| 198 |
+
"## **6. Baseline & Available Tools**\n",
|
| 199 |
+
"\n",
|
| 200 |
+
"- Below you can find the baseline solution.\n",
|
| 201 |
+
"- The training set and pretrained models are in `training_set` folder.\n",
|
| 202 |
+
"- The highest score by the Scientific Committee for this task is 0.54, this score is used for score unification.\n",
|
| 203 |
+
"- The baseline score by the Scientific Committee for this task is 0.20, this score is used for score unification.\n",
|
| 204 |
+
"\n",
|
| 205 |
+
"\n",
|
| 206 |
+
"### AI-Guesser API\n",
|
| 207 |
+
"\n",
|
| 208 |
+
"You can assess the AI-guesser for you to play around with. See the following code on how to access the guesser. It is recommended to implement exponential retry logic as network failures might occur. \n",
|
| 209 |
+
"\n",
|
| 210 |
+
"```python\n",
|
| 211 |
+
"guesser_response = httpx.post(f\"{API_URL}/guess\", json={\n",
|
| 212 |
+
" \"clues\": clues,\n",
|
| 213 |
+
" \"options\": options\n",
|
| 214 |
+
" }, headers={\n",
|
| 215 |
+
" \"Authorization\": f\"Bearer {SCORER_API_KEY}\"\n",
|
| 216 |
+
" }, timeout=60).json()\n",
|
| 217 |
+
"```\n",
|
| 218 |
+
"\n",
|
| 219 |
+
"**Important**: The AI-Guesser API will not be available on the inference machines. In other words, do **NOT** call the api in your submission notebooks. This is only for you to validate/train your model locally. You may attach your model weights, training data, etc. via a Bohrium dataset. Refer to the Requirements section.\n",
|
| 220 |
+
"\n",
|
| 221 |
+
"### Environment\n",
|
| 222 |
+
"\n",
|
| 223 |
+
"We installed `vllm`, `sglang` and `unsloth` in environment for LLM inference and fine tuning. \n",
|
| 224 |
+
"Additionally, we provide access to the following huggingface models via a `training_set`:\n",
|
| 225 |
+
"\n",
|
| 226 |
+
"#### Embedding Models\n",
|
| 227 |
+
"```\n",
|
| 228 |
+
"sentence-transformers/all-MiniLM-L6-v2\n",
|
| 229 |
+
"sentence-transformers/all-MiniLM-L12-v2\n",
|
| 230 |
+
"sentence-transformers/all-mpnet-base-v2\n",
|
| 231 |
+
"sentence-transformers/paraphrase-mpnet-base-v2\n",
|
| 232 |
+
"sentence-transformers/paraphrase-MiniLM-L6-v2\n",
|
| 233 |
+
"intfloat/e5-small\n",
|
| 234 |
+
"intfloat/e5-base\n",
|
| 235 |
+
"intfloat/e5-large\n",
|
| 236 |
+
"intfloat/e5-small-v2\n",
|
| 237 |
+
"intfloat/e5-base-v2\n",
|
| 238 |
+
"intfloat/e5-large-v2\n",
|
| 239 |
+
"intfloat/multilingual-e5-small\n",
|
| 240 |
+
"intfloat/multilingual-e5-base\n",
|
| 241 |
+
"Alibaba-NLP/gte-modernbert-base\n",
|
| 242 |
+
"Snowflake/snowflake-arctic-embed-xs\n",
|
| 243 |
+
"Snowflake/snowflake-arctic-embed-s\n",
|
| 244 |
+
"Snowflake/snowflake-arctic-embed-m\n",
|
| 245 |
+
"Snowflake/snowflake-arctic-embed-m-long\n",
|
| 246 |
+
"Snowflake/snowflake-arctic-embed-l\n",
|
| 247 |
+
"BAAI/bge-large-en\n",
|
| 248 |
+
"BAAI/bge-base-en\n",
|
| 249 |
+
"BAAI/bge-small-en\n",
|
| 250 |
+
"BAAI/bge-large-en-v1.5\n",
|
| 251 |
+
"BAAI/bge-base-en-v1.5\n",
|
| 252 |
+
"BAAI/bge-small-en-v1.5\n",
|
| 253 |
+
"WhereIsAI/UAE-Large-V1\n",
|
| 254 |
+
"mixedbread-ai/mxbai-embed-large-v1\n",
|
| 255 |
+
"```\n",
|
| 256 |
+
"\n",
|
| 257 |
+
"#### Small LLMs\n",
|
| 258 |
+
"\n",
|
| 259 |
+
"```\n",
|
| 260 |
+
"Qwen/Qwen3-0.6B\n",
|
| 261 |
+
"Qwen/Qwen2.5-0.5B\n",
|
| 262 |
+
"Qwen/Qwen2.5-0.5B-Instruct\n",
|
| 263 |
+
"unsloth/Qwen3-0.6B\n",
|
| 264 |
+
"facebook/opt-350m\n",
|
| 265 |
+
"facebook/opt-125m\n",
|
| 266 |
+
"```\n",
|
| 267 |
+
"\n",
|
| 268 |
+
"\n",
|
| 269 |
+
"## **7. Requirements**\n",
|
| 270 |
+
"\n",
|
| 271 |
+
"### Overall Requirements\n",
|
| 272 |
+
"\n",
|
| 273 |
+
"- Maximum submission limit: **15 times**. Only successful submissions (i.e., those receive a score on Leaderboard A) will be counted toward the submission limit.\n",
|
| 274 |
+
"- Testing environment restrictions: The test machine will run your Notebook within **10 minutes**. If the execution time exceeds **10 minutes**, the system will forcibly terminate and return a feedback of “Timeout” or “Failed”.\n",
|
| 275 |
+
"- Data and model submission: In this task, contestants should submit a Notebook and have the option to submit 1 attached dataset generated by themselves. The dataset must not exceed `2GB` in total size. You are warned that attaching a very large dataset might prolong the testing process, as the dataset needs to be mounted to the inference machine. While this process does not count towards the execution time limit, it will take longer for you to be able to see and select your submissions.\n",
|
| 276 |
+
"- Network: For the on-site stage, the test machine cannot connect to the internet. In other words, downloading commands such as 'pip' and 'conda' or trying to call APIs will not work. Specific to this problem, the testing machines cannot access the guessor API nor the LLM proxy.\n",
|
| 277 |
+
"\n",
|
| 278 |
+
"### API Access Limitations\n",
|
| 279 |
+
"\n",
|
| 280 |
+
"Your token will grant you 12,500 `POST` requests to `/guess` endpoint of the AI-guesser API. \n",
|
| 281 |
+
"\n",
|
| 282 |
+
"- If successful, this will return a dictionary in the form `{'guesses': ['firefighter', 'fire inspector', 'fire marshal', 'fire warden', 'fire safety officer', 'smokejumper', 'pyrotechnician', 'firewatcher', 'chef', 'cook'], 'message': 'Generated 10 guesses'}`. \n",
|
| 283 |
+
"\n",
|
| 284 |
+
"- If unsuccessful, this will either raise an `HTTPStatusError` and return `{'detail': 'error message'}`, or return `{'guesses': [], 'message': 'unable to generate guesses'}`. \n",
|
| 285 |
+
"- Usually, the former is because you have exceeded the 12,500 limit of your token, or you tried to make more than 1000 requests within 1 minute, and the latter is because your clues exceeded 4 sequences or exceeded 8 markers in 1 sequence. \n",
|
| 286 |
+
"- Refer to the error message for details.\n",
|
| 287 |
+
"- There might be 1-2 failures in 1000 requests, 'retry' mechanism is provided in [baseline.ipynb](https://ioai.bohrium.com/notebooks/26681337682).\n",
|
| 288 |
+
"\n",
|
| 289 |
+
"\n"
|
| 290 |
+
]
|
| 291 |
+
},
|
| 292 |
+
{
|
| 293 |
+
"cell_type": "markdown",
|
| 294 |
+
"id": "fc6bbc24",
|
| 295 |
+
"metadata": {},
|
| 296 |
+
"source": [
|
| 297 |
+
"### Imports"
|
| 298 |
+
]
|
| 299 |
+
},
|
| 300 |
+
{
|
| 301 |
+
"cell_type": "code",
|
| 302 |
+
"execution_count": null,
|
| 303 |
+
"id": "26a701aa",
|
| 304 |
+
"metadata": {},
|
| 305 |
+
"outputs": [],
|
| 306 |
+
"source": [
|
| 307 |
+
"import vllm\n",
|
| 308 |
+
"from vllm import LLM, SamplingParams\n",
|
| 309 |
+
"from vllm.sampling_params import GuidedDecodingParams\n",
|
| 310 |
+
"from pydantic import BaseModel"
|
| 311 |
+
]
|
| 312 |
+
},
|
| 313 |
+
{
|
| 314 |
+
"cell_type": "code",
|
| 315 |
+
"execution_count": null,
|
| 316 |
+
"id": "ab3b9844-a68b-437d-9a29-4c24f2827878",
|
| 317 |
+
"metadata": {},
|
| 318 |
+
"outputs": [],
|
| 319 |
+
"source": [
|
| 320 |
+
"import random\n",
|
| 321 |
+
"import numpy as np\n",
|
| 322 |
+
"import torch\n",
|
| 323 |
+
"\n",
|
| 324 |
+
"seed = 42\n",
|
| 325 |
+
"\n",
|
| 326 |
+
"random.seed(seed) # Python built-in random\n",
|
| 327 |
+
"np.random.seed(seed) # NumPy\n",
|
| 328 |
+
"torch.manual_seed(seed) # PyTorch (CPU)\n",
|
| 329 |
+
"torch.cuda.manual_seed(seed) # PyTorch (single GPU)\n",
|
| 330 |
+
"torch.cuda.manual_seed_all(seed) # PyTorch (all GPUs)\n",
|
| 331 |
+
"\n",
|
| 332 |
+
"# Ensures deterministic behavior\n",
|
| 333 |
+
"torch.backends.cudnn.deterministic = True\n",
|
| 334 |
+
"torch.backends.cudnn.benchmark = False"
|
| 335 |
+
]
|
| 336 |
+
},
|
| 337 |
+
{
|
| 338 |
+
"cell_type": "markdown",
|
| 339 |
+
"id": "ce0b4e27-a439-4608-b71c-e393157c2e5a",
|
| 340 |
+
"metadata": {},
|
| 341 |
+
"source": [
|
| 342 |
+
"**Note on Output Determinism**\n",
|
| 343 |
+
"\n",
|
| 344 |
+
"In the above code block, we fix the random seed to ensure that results are reproducible when running the baseline model alone. This is a common practice to eliminate output variance caused by stochastic operations.\n",
|
| 345 |
+
"However, in this specific task, your model is required to interact dynamically with an AI guesser. The guesser is powered by a large language model, which may produce different responses to the same input due to inherent randomness in its decoding process. Therefore, even when given the same set of hints, the guesser’s answers may vary across runs.\n",
|
| 346 |
+
"As a result, you may observe fluctuations in the reported scores across multiple identical submissions. This is expected behavior and does not indicate a bug in the evaluation system."
|
| 347 |
+
]
|
| 348 |
+
},
|
| 349 |
+
{
|
| 350 |
+
"cell_type": "markdown",
|
| 351 |
+
"id": "f46cc2bf",
|
| 352 |
+
"metadata": {},
|
| 353 |
+
"source": [
|
| 354 |
+
"### Accessing AI-Guesser\n",
|
| 355 |
+
"\n",
|
| 356 |
+
"You can asses the AI-guesser for you to play around with, through the API_URL server. See the following code on how to access the guesser.\n",
|
| 357 |
+
"\n",
|
| 358 |
+
"Your token will grant you $12,500$ `POST` requests to `/guess`. You will also be limited to $1000$ calls per minute.\n",
|
| 359 |
+
"\n"
|
| 360 |
+
]
|
| 361 |
+
},
|
| 362 |
+
{
|
| 363 |
+
"cell_type": "code",
|
| 364 |
+
"execution_count": null,
|
| 365 |
+
"id": "a021e386",
|
| 366 |
+
"metadata": {},
|
| 367 |
+
"outputs": [],
|
| 368 |
+
"source": [
|
| 369 |
+
"API_URL = \"https://concepts-judge-server-production-1188.up.railway.app\"\n",
|
| 370 |
+
"# This url will not be accessible on the inference/testing machines. Do not try to call the api in your submitted code.\n",
|
| 371 |
+
"# The testing machine will use a secret url to do call API for evalutaion.\n",
|
| 372 |
+
"# SCORER_API_KEY = \"sk-ioai-XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX\" # If you want to use API, use the api key provided to you.\n",
|
| 373 |
+
"# If you do not know how to use it. Just use the model we provide to you."
|
| 374 |
+
]
|
| 375 |
+
},
|
| 376 |
+
{
|
| 377 |
+
"cell_type": "code",
|
| 378 |
+
"execution_count": null,
|
| 379 |
+
"id": "20ffe741",
|
| 380 |
+
"metadata": {},
|
| 381 |
+
"outputs": [],
|
| 382 |
+
"source": [
|
| 383 |
+
"import math, random\n",
|
| 384 |
+
"import httpx\n",
|
| 385 |
+
"from tenacity import retry, stop_after_attempt, wait_exponential, retry_if_exception_type, retry_if_exception\n",
|
| 386 |
+
"\n",
|
| 387 |
+
"class GameClient:\n",
|
| 388 |
+
" def ndcg_at_10(self, predictions, correct_answer):\n",
|
| 389 |
+
" if correct_answer not in predictions:\n",
|
| 390 |
+
" return 0.0\n",
|
| 391 |
+
" try:\n",
|
| 392 |
+
" rank = predictions[:10].index(correct_answer) + 1\n",
|
| 393 |
+
" except ValueError:\n",
|
| 394 |
+
" return 0.0\n",
|
| 395 |
+
"\n",
|
| 396 |
+
" return 1 / math.log2(rank + 1)\n",
|
| 397 |
+
"\n",
|
| 398 |
+
" def hits_at_10(self, predictions, correct_answer):\n",
|
| 399 |
+
" return 1.0 if correct_answer in predictions[:10] else 0.0\n",
|
| 400 |
+
"\n",
|
| 401 |
+
" def __init__(self):\n",
|
| 402 |
+
" self._random_options = ['gym', 'dinosaur', 'camel', 'desk', 'chicken', 'suitcase', 'thief', 'penguin', 'bat', 'painter', 'yogurt', 'chocolate', 'football', 'wallet', 'magician', 'shoes', 'bank', 'church', 'chewing gum', 'fashion', 'chainsaw', 'escalator', 'scarf', 'lawyer', 'eagle', 'credit card', 'garden hose', 'glider', 'crosswalk', 'subway', 'fireworks', 'marshmallow', 'cookies', 'curtains', 'dining room', 'cars', 'wedding', 'guitar', 'coffee', 'mouse', 'meat', 'scale', 'train tracks', 'zebra', 'fairy', 'quit', 'museum', 'kangaroo', 'surfboard', 'cheese', 'nightmare', 'jellyfish', 'koala', 'strawberry', 'tiger', 'mailbox', 'kettle', 'potato', 'janitor', 'lighthouse', 'crocodile', 'charger', 'doctor', 'peacock', 'peanut', 'popcorn', 't-shirt', 'fertilizer', 'keyboard', 'umbrella', 'pool', 'watercolor', 'mango', 'xylophone', 'bathroom', 'ice cube', 'giraffe', 'garage', 'cabin', 'plankton', 'pig', 'vulture', 'frame', 'polar bear', 'microscope', 'snake', 'skeleton', 'rocket', 'backpack', 'jacket', 'bedroom', 'castle', 'horse', 'dragonfly', 'hotel', 'cyclist', 'mask', 'restaurant', 'toothpaste', 'angel', 'whistle', 'wrestling', 'eclipse', 'hermit crabs', 'horn', 'boxers', 'volcano', 'fire station', 'toothbrush', 'egg', 'straw', 'rice', 'diamond', 'vitamins', 'tricycle', 'bottle-opener', 'panther', 'ice skates', 'theater', 'gas mask', 'game console', 'path', 'scorpion', 'snowboard', 'crab', 'pie', 'octopus', 'mustache', 'pepper grinder', 'swings', 'palm tree', 'well', 'sewing machine', 'key', 'station', 'mosque', 'chameleon', 'cherry', 'parrot', 'leggings', 'radio', 'brick', 'sunflower', 'hammer', 'carrot', 'radar', 'kite', 'bathtub', 'rhinoceros', 'spoon', 'orchestra', 'gravity', 'flute', 'lipstick', 'school', 'meteorite', 'politician', 'ladder', 'lawnmower', 'computer', 'wheel', 'airport', 'firefighter', 'porch', 'police station', 'queen', 'mayonnaise', 'alumunium foil', 'lion', 'helmet', 'teacher', 'tea', 'fan', 'piano', 'snail', 'farmer', 'harbor', 'nurse', 'sunglasses', 'bee', 'postal worker', 'market', 'plank', 'steering wheel', 'squirrel', 'netting', 'dragon', 'cafeteria', 'millennium', 'spinach', 'fork', 'cabbage', 'ping-pong', 'lock', 'submarine', 'dictionary', 'vaccine', 'soda', 'skirt', 'toaster', 'shorts', 'circus', 'flowerpot', 'lobster', 'rainbow', 'cockroach', 'frog', 'basket ball', 'chilli pepper', 'pajamas', 'crossword', 'light bulb', 'drill', 'beaver', 'daisy', 'river', 'yo-yo', 'harmonica', 'soap', 'igloo', 'sausage', 'deer', 'sailboat', 'fish', 'mosquito', 'can', 'rat', 'frying pan', 'barcode', 'sunscreen', 'ferret', 'whale', 'duck', 'shirt', 'vacuum', 'detective', 'perfume', 'seal', 'raincoat', 'alien', 'bull', 'nest', 'butterfly', 'eraser', 'hedgehog', 'panda', 'refrigerator', 'monocle', 'window', 'kitchen', 'mole', 'speaker', 'waiter', 'salad', 'dolphin', 'storm', 'drums', 'spiderweb', 'bicycle', 'monkey', 'flamingo', 'prison', 'bowling', 'pencil sharpner', 'photo', 'printer', 'robe', 'seahorse', 'doorbell', 'gloves', 'alcohol', 'diving suit', 'shotgun', 'hairbrush', 'cactus', 'ambulance', 'hula hoop', 'snowman', 'mountain', 'unicorn', 'suit', 'cake', 'cow', 'sled', 'boar', 'barbecue', 'trash can', 'slingshot', 'banana', 'dam', 'hat', 'milk', 'shell', 'broom', 'fisherman', 'bucket', 'bell', 'tracktor', 'fly', 'spider', 'carpet', 'coconut tree', 'movie theater', 'socks', 'soldier', 'watering can', 'accountant', 'microphone', 'toothpick', 'wolf', 'trumpet', 'apple', 'library', 'cork', 'zipper', 'pan', 'doghouse', 'dynamite', 'swan', 'grasshopper', 'beach', 'starfish', 'police officer', 'board game', 'magnet', 'cucumber', 'fire extinguisher', 'sundial', 'mechanic', 'lighter', 'shovel', 'shark', 'notebook', 'ostrich', 'bodyguard', 'binoculars', 'parachute', 'drone', 'kiwi', 'ghost', 'baker', 'robot', 'postcard', 'horseshoe', 'karaoke', 'billiards', 'palace', 'hospital', 'compass', 'truck', 'holiday', 'lake', 'cave', 'space station', 'mushroom', 'magnifying glass', 'fox', 'bread', 'rose', 'windmill', 'pirate', 'earring', 'hunter', 'princess', 'calculator', 'clown', 'watch', 'pilot', 'mustard', 'swordfish', 'darts', 'microwave oven', 'plumber', 'sword']\n",
|
| 403 |
+
"\n",
|
| 404 |
+
" @retry(\n",
|
| 405 |
+
" stop=stop_after_attempt(3),\n",
|
| 406 |
+
" wait=wait_exponential(multiplier=1, min=4, max=10),\n",
|
| 407 |
+
" retry=retry_if_exception_type((httpx.TimeoutException, httpx.ConnectError, httpx.RequestError)) |\n",
|
| 408 |
+
" retry_if_exception(lambda e: isinstance(e, httpx.HTTPStatusError) and e.response.is_server_error) # Retry on connection errors or server side errors.\n",
|
| 409 |
+
" )\n",
|
| 410 |
+
" def _make_api_call(self, clues, options):\n",
|
| 411 |
+
" response = httpx.post(f\"{API_URL}/guess\", json={\n",
|
| 412 |
+
" \"clues\": clues,\n",
|
| 413 |
+
" \"options\": options\n",
|
| 414 |
+
" }, headers={\n",
|
| 415 |
+
" \"Authorization\": f\"Bearer {SCORER_API_KEY}\"\n",
|
| 416 |
+
" }, timeout=60)\n",
|
| 417 |
+
" \n",
|
| 418 |
+
" response.raise_for_status()\n",
|
| 419 |
+
" \n",
|
| 420 |
+
" guesser_response = response.json()\n",
|
| 421 |
+
" \n",
|
| 422 |
+
" if \"guesses\" not in guesser_response:\n",
|
| 423 |
+
" raise ValueError(f\"Unable to generate guesses: {guesser_response}\")\n",
|
| 424 |
+
" if not isinstance(guesser_response[\"guesses\"], list):\n",
|
| 425 |
+
" raise ValueError(f\"Guesses is not a list: {guesser_response}\")\n",
|
| 426 |
+
" \n",
|
| 427 |
+
" return guesser_response\n",
|
| 428 |
+
"\n",
|
| 429 |
+
" def simulate_game(self, clues, expected_answer, distractors = []):\n",
|
| 430 |
+
" expected_answer = expected_answer.lower()\n",
|
| 431 |
+
" if expected_answer in distractors:\n",
|
| 432 |
+
" options = []\n",
|
| 433 |
+
" else:\n",
|
| 434 |
+
" options = [expected_answer]\n",
|
| 435 |
+
" if len(distractors) > 0:\n",
|
| 436 |
+
" options.extend([d.lower() for d in distractors])\n",
|
| 437 |
+
" options = options[:100]\n",
|
| 438 |
+
"\n",
|
| 439 |
+
" # fill in options until the size is 100 with random options\n",
|
| 440 |
+
" # set seed based on the expected_answers\n",
|
| 441 |
+
" if len(options) < 100:\n",
|
| 442 |
+
" random.seed(expected_answer)\n",
|
| 443 |
+
" options.extend(random.choices(self._random_options, k=100-len(options)))\n",
|
| 444 |
+
" # then shuffle\n",
|
| 445 |
+
" random.shuffle(options)\n",
|
| 446 |
+
"\n",
|
| 447 |
+
" try:\n",
|
| 448 |
+
" guesser_response = self._make_api_call(clues, options)\n",
|
| 449 |
+
" predictions = [p.lower() for p in guesser_response[\"guesses\"]]\n",
|
| 450 |
+
" return {\n",
|
| 451 |
+
" \"predictions\": predictions,\n",
|
| 452 |
+
" \"hit@10\": self.hits_at_10(predictions, expected_answer),\n",
|
| 453 |
+
" \"NDCG@10\": self.ndcg_at_10(predictions, expected_answer)\n",
|
| 454 |
+
" }\n",
|
| 455 |
+
" \n",
|
| 456 |
+
" except Exception as e:\n",
|
| 457 |
+
"\n",
|
| 458 |
+
" if isinstance(e, httpx.HTTPStatusError):\n",
|
| 459 |
+
" print(f\"HTTP Status Error {e.response.status_code}: {e.response.text}\")\n",
|
| 460 |
+
" try:\n",
|
| 461 |
+
" error_detail = e.response.json().get(\"detail\", \"Unknown error\")\n",
|
| 462 |
+
" print(f\"Error details: {error_detail}\")\n",
|
| 463 |
+
" except:\n",
|
| 464 |
+
" print(f\"Could not parse error response {e.response.text}\")\n",
|
| 465 |
+
" \n",
|
| 466 |
+
" elif isinstance(e, ValueError):\n",
|
| 467 |
+
" print(f\"Value error: {e}\")\n",
|
| 468 |
+
"\n",
|
| 469 |
+
" elif isinstance(e, httpx.TimeoutException):\n",
|
| 470 |
+
" print(\"request timed out after retries\")\n",
|
| 471 |
+
"\n",
|
| 472 |
+
" elif isinstance(e, httpx.ConnectError):\n",
|
| 473 |
+
" print(f\"Could not connect to {API_URL} after retries\")\n",
|
| 474 |
+
"\n",
|
| 475 |
+
" elif isinstance(e, httpx.RequestError):\n",
|
| 476 |
+
" print(f\"Request error after retries: {e}\")\n",
|
| 477 |
+
"\n",
|
| 478 |
+
" else:\n",
|
| 479 |
+
" print(f\"Unknown error: {e}\")\n",
|
| 480 |
+
"\n",
|
| 481 |
+
" return {\n",
|
| 482 |
+
" \"predictions\": [],\n",
|
| 483 |
+
" \"hit@10\": 0.0,\n",
|
| 484 |
+
" \"NDCG@10\": 0.0\n",
|
| 485 |
+
" }"
|
| 486 |
+
]
|
| 487 |
+
},
|
| 488 |
+
{
|
| 489 |
+
"cell_type": "code",
|
| 490 |
+
"execution_count": null,
|
| 491 |
+
"id": "a7929fa5",
|
| 492 |
+
"metadata": {},
|
| 493 |
+
"outputs": [],
|
| 494 |
+
"source": [
|
| 495 |
+
"game_client = GameClient()\n",
|
| 496 |
+
"\n",
|
| 497 |
+
"# the clue for samurai\n",
|
| 498 |
+
"clue = [[4, 35],\n",
|
| 499 |
+
" [16, 116, 85, 106],\n",
|
| 500 |
+
" [43, 102]]\n",
|
| 501 |
+
"\n",
|
| 502 |
+
"'''\n",
|
| 503 |
+
"# You can refer to the following code for calling the judge api. Don't forget to comment out this part before submission, otherwise your notebook will not run.\n",
|
| 504 |
+
"# you can call simulate game, given your clues and the expected answer.\n",
|
| 505 |
+
"# the game client will randomly generate 100 options.\n",
|
| 506 |
+
"# The answer will be automatically added as one of the options.\n",
|
| 507 |
+
"# note that capitalization does not matter, the client will treat all texts as lowercase.\n",
|
| 508 |
+
"prediction = game_client.simulate_game(clue, \"Samurai\")\n",
|
| 509 |
+
"\n",
|
| 510 |
+
"# it will print the prediction, as well as the score of the prediction (more later)\n",
|
| 511 |
+
"print(prediction)\n",
|
| 512 |
+
"\n",
|
| 513 |
+
"# you might also want to put your own distractors, which will be added into the set of options.\n",
|
| 514 |
+
"# It will randomly fill in the rest of options until it has 100 options\n",
|
| 515 |
+
"prediction = game_client.simulate_game(clue, \"Samurai\",\n",
|
| 516 |
+
" distractors=['cat', 'dog', 'castle', 'blacksmith', 'martial artist', 'hunter',\n",
|
| 517 |
+
" 'warrior', 'knight', 'viking', 'janissary', 'chevalier', 'imperial guard', 'swordsman', 'gladiator', 'marksman', 'police officer'])\n",
|
| 518 |
+
"print(prediction)\n",
|
| 519 |
+
"'''"
|
| 520 |
+
]
|
| 521 |
+
},
|
| 522 |
+
{
|
| 523 |
+
"cell_type": "markdown",
|
| 524 |
+
"id": "17c8559a-540a-4a10-80dd-bf2a452bc098",
|
| 525 |
+
"metadata": {},
|
| 526 |
+
"source": [
|
| 527 |
+
"### Data Loading"
|
| 528 |
+
]
|
| 529 |
+
},
|
| 530 |
+
{
|
| 531 |
+
"cell_type": "code",
|
| 532 |
+
"execution_count": null,
|
| 533 |
+
"id": "8730c968",
|
| 534 |
+
"metadata": {},
|
| 535 |
+
"outputs": [],
|
| 536 |
+
"source": [
|
| 537 |
+
"from datasets import load_from_disk\n",
|
| 538 |
+
"TRAIN_PATH = \"./training_set/\" \n",
|
| 539 |
+
"# The training set is deployed automatically in the testing machine. \n",
|
| 540 |
+
"# You notebook can access the TRAIN_PATH even if you do not mount it along with notebook.\n",
|
| 541 |
+
"DESCRIPTIONS = TRAIN_PATH + \"hint_descriptions\"\n",
|
| 542 |
+
"# The training set is deployed automatically in the testing machine. \n",
|
| 543 |
+
"# You notebook can access the TRAIN_PATH even if you do not mount it along with notebook.\n",
|
| 544 |
+
"\n",
|
| 545 |
+
"hint_descriptions = load_from_disk(DESCRIPTIONS)['train']\n",
|
| 546 |
+
"hint_descriptions = {\n",
|
| 547 |
+
" x['ID']: {'description': x['Description'], 'icons': x['image']}\n",
|
| 548 |
+
" for x in hint_descriptions\n",
|
| 549 |
+
"}"
|
| 550 |
+
]
|
| 551 |
+
},
|
| 552 |
+
{
|
| 553 |
+
"cell_type": "code",
|
| 554 |
+
"execution_count": null,
|
| 555 |
+
"id": "f1804b3b",
|
| 556 |
+
"metadata": {},
|
| 557 |
+
"outputs": [],
|
| 558 |
+
"source": [
|
| 559 |
+
"valid_hints = [x['description'] for x in hint_descriptions.values()]\n",
|
| 560 |
+
"hint_to_id = {\n",
|
| 561 |
+
" x['description']: xid\n",
|
| 562 |
+
" for xid, x in hint_descriptions.items()\n",
|
| 563 |
+
"}\n",
|
| 564 |
+
"\n",
|
| 565 |
+
"print(valid_hints)\n",
|
| 566 |
+
"print(hint_to_id)"
|
| 567 |
+
]
|
| 568 |
+
},
|
| 569 |
+
{
|
| 570 |
+
"cell_type": "code",
|
| 571 |
+
"execution_count": null,
|
| 572 |
+
"id": "118f6ada",
|
| 573 |
+
"metadata": {},
|
| 574 |
+
"outputs": [],
|
| 575 |
+
"source": [
|
| 576 |
+
"TRAINING_SET = TRAIN_PATH + \"train\"\n",
|
| 577 |
+
"dev = load_from_disk(TRAINING_SET)['train']\n",
|
| 578 |
+
"print(dev)\n",
|
| 579 |
+
"print(dev[0])"
|
| 580 |
+
]
|
| 581 |
+
},
|
| 582 |
+
{
|
| 583 |
+
"cell_type": "code",
|
| 584 |
+
"execution_count": null,
|
| 585 |
+
"id": "50a07d22",
|
| 586 |
+
"metadata": {},
|
| 587 |
+
"outputs": [],
|
| 588 |
+
"source": [
|
| 589 |
+
"from typing import Literal, List, Optional\n",
|
| 590 |
+
"ValidHint = Literal[*valid_hints]\n",
|
| 591 |
+
"\n",
|
| 592 |
+
"class Hints(BaseModel):\n",
|
| 593 |
+
" hints_1: List[ValidHint]\n",
|
| 594 |
+
" hints_2: List[ValidHint]\n",
|
| 595 |
+
" hints_3: List[ValidHint]\n",
|
| 596 |
+
" hints_4: List[ValidHint]\n",
|
| 597 |
+
"\n",
|
| 598 |
+
" def to_result(self):\n",
|
| 599 |
+
" hints = [self.hints_1, self.hints_2, self.hints_3, self.hints_4]\n",
|
| 600 |
+
" result = []\n",
|
| 601 |
+
" for hintlist in hints:\n",
|
| 602 |
+
" cur_hintlist = [hint_to_id[hint] for hint in hintlist[:8]]\n",
|
| 603 |
+
" result.append(cur_hintlist)\n",
|
| 604 |
+
" return result\n",
|
| 605 |
+
"\n",
|
| 606 |
+
"class ClueGiver:\n",
|
| 607 |
+
" def __init__(self):\n",
|
| 608 |
+
" self.llm = LLM(\"/bohr/models-b08n/v1/models/facebook/opt-125m\")\n",
|
| 609 |
+
" # The models in select_hf_models are deployed automatically in the testing machine. \n",
|
| 610 |
+
" # You notebook can access the select_hf_models even if you do not mount it along with notebook.\n",
|
| 611 |
+
" json_schema = Hints.model_json_schema()\n",
|
| 612 |
+
" self.sampling_params = SamplingParams(\n",
|
| 613 |
+
" guided_decoding=GuidedDecodingParams(\n",
|
| 614 |
+
" json=json_schema,\n",
|
| 615 |
+
" ),\n",
|
| 616 |
+
" max_tokens=5096,\n",
|
| 617 |
+
" frequency_penalty=0.5,\n",
|
| 618 |
+
" presence_penalty=0.8\n",
|
| 619 |
+
" )\n",
|
| 620 |
+
"\n",
|
| 621 |
+
" def construct_clues(self, answers: List[str], options: List[List[str]]):\n",
|
| 622 |
+
" prompts = []\n",
|
| 623 |
+
" for answer, options in zip(answers, options):\n",
|
| 624 |
+
" prompt = (\n",
|
| 625 |
+
" f\"Your valid list of clues are: {valid_hints}. \"\n",
|
| 626 |
+
" \"Your job is a clue giver. You will help the guesser pick the correct answer from a range of options.\"\n",
|
| 627 |
+
" \"You must output at least 1 hint and at most 8 hints for each sequence. \"\n",
|
| 628 |
+
" \"Please output a json object with the key 'hints_1', 'hints_2', 'hints_3', and 'hints_4', and the value being a list of hints. \"\n",
|
| 629 |
+
" \"Example: {\"\n",
|
| 630 |
+
" \"'hints_1': [\\\"Work\\\\nOccupation\\\", \\\"Idea\\\\nIntelligence\\\\nConcept\\\"], \"\n",
|
| 631 |
+
" \"'hints_2': [\\\"Fauna\\\\nAnimal\\\", \\\"Flora\\\\nPlant\\\\nNature\\\"], \"\n",
|
| 632 |
+
" \"'hints_3': [\\\"Object\\\\nBox\\\", \\\"Art\\\\nSculpture - Painting\\\\nDrawing - Cartoon\\\"], \"\n",
|
| 633 |
+
" \"'hints_4': [\\\"Work\\\\nOccupation\\\", \\\"Idea\\\\nIntelligence\\\\nConcept\\\"]\"\n",
|
| 634 |
+
" \"}\"\n",
|
| 635 |
+
" f\"The options the guesser has to choose from are: {options}.\"\n",
|
| 636 |
+
" f\"Please construct sequences of hints that are most relevant to the answer {answer}. \"\n",
|
| 637 |
+
" )\n",
|
| 638 |
+
" prompts.append(prompt)\n",
|
| 639 |
+
" # batch mode: pass a list of prompts\n",
|
| 640 |
+
" hints_batch = self.llm.generate(prompts=prompts, sampling_params=self.sampling_params)\n",
|
| 641 |
+
" results = []\n",
|
| 642 |
+
" for i, hints in enumerate(hints_batch):\n",
|
| 643 |
+
" # print(hints.outputs)\n",
|
| 644 |
+
" # print(f\"len of token ids: {len(hints.outputs[0].token_ids)}\")\n",
|
| 645 |
+
" txt = hints.outputs[0].text\n",
|
| 646 |
+
" # print(txt)\n",
|
| 647 |
+
" try:\n",
|
| 648 |
+
" hints_obj = Hints.model_validate_json(txt)\n",
|
| 649 |
+
" results.append(hints_obj.to_result())\n",
|
| 650 |
+
" except Exception as e:\n",
|
| 651 |
+
" print(f\"Error parsing hints for answer {answers[i]}: {e}\")\n",
|
| 652 |
+
" results.append([[1,2,3,4]])\n",
|
| 653 |
+
" return results"
|
| 654 |
+
]
|
| 655 |
+
},
|
| 656 |
+
{
|
| 657 |
+
"cell_type": "code",
|
| 658 |
+
"execution_count": null,
|
| 659 |
+
"id": "c21319c5",
|
| 660 |
+
"metadata": {},
|
| 661 |
+
"outputs": [],
|
| 662 |
+
"source": [
|
| 663 |
+
"clue_giver = ClueGiver()"
|
| 664 |
+
]
|
| 665 |
+
},
|
| 666 |
+
{
|
| 667 |
+
"cell_type": "code",
|
| 668 |
+
"execution_count": null,
|
| 669 |
+
"id": "01a07b30",
|
| 670 |
+
"metadata": {},
|
| 671 |
+
"outputs": [],
|
| 672 |
+
"source": [
|
| 673 |
+
"res_clues = clue_giver.construct_clues([x['label'] for x in dev], [x['options'] for x in dev])"
|
| 674 |
+
]
|
| 675 |
+
},
|
| 676 |
+
{
|
| 677 |
+
"cell_type": "code",
|
| 678 |
+
"execution_count": null,
|
| 679 |
+
"id": "bf138945",
|
| 680 |
+
"metadata": {},
|
| 681 |
+
"outputs": [],
|
| 682 |
+
"source": [
|
| 683 |
+
"'''\n",
|
| 684 |
+
"# You may use the following code to evaluate your model. Don't forget to comment out this section before submission, as the inference machine will not have access to the judge api.\n",
|
| 685 |
+
"from tqdm import tqdm\n",
|
| 686 |
+
"from concurrent.futures import ThreadPoolExecutor, as_completed\n",
|
| 687 |
+
"\n",
|
| 688 |
+
"def simulate_one(i_data):\n",
|
| 689 |
+
" i, data = i_data\n",
|
| 690 |
+
" clues = res_clues[i]\n",
|
| 691 |
+
" prediction = game_client.simulate_game(clues, data['label'])\n",
|
| 692 |
+
" return prediction\n",
|
| 693 |
+
"\n",
|
| 694 |
+
"predictions = []\n",
|
| 695 |
+
"with ThreadPoolExecutor() as executor:\n",
|
| 696 |
+
" futures = [executor.submit(simulate_one, (i, data)) for i, data in enumerate(dev)]\n",
|
| 697 |
+
" for f in tqdm(as_completed(futures), total=len(futures)):\n",
|
| 698 |
+
" predictions.append(f.result())\n",
|
| 699 |
+
"\n",
|
| 700 |
+
"print(\"Final Score: \")\n",
|
| 701 |
+
"print(sum([p['hit@10'] for p in predictions]) * 0.9 + sum([p['NDCG@10'] for p in predictions]) * 0.1)\n",
|
| 702 |
+
"'''"
|
| 703 |
+
]
|
| 704 |
+
},
|
| 705 |
+
{
|
| 706 |
+
"cell_type": "markdown",
|
| 707 |
+
"id": "a516aaa2-0153-4e7d-bb31-b802fe702c00",
|
| 708 |
+
"metadata": {},
|
| 709 |
+
"source": [
|
| 710 |
+
"### Clean Gpu Cache"
|
| 711 |
+
]
|
| 712 |
+
},
|
| 713 |
+
{
|
| 714 |
+
"cell_type": "code",
|
| 715 |
+
"execution_count": null,
|
| 716 |
+
"id": "a33b2a1e",
|
| 717 |
+
"metadata": {},
|
| 718 |
+
"outputs": [],
|
| 719 |
+
"source": [
|
| 720 |
+
"import torch\n",
|
| 721 |
+
"\n",
|
| 722 |
+
"del clue_giver\n",
|
| 723 |
+
"\n",
|
| 724 |
+
"torch.cuda.empty_cache()"
|
| 725 |
+
]
|
| 726 |
+
},
|
| 727 |
+
{
|
| 728 |
+
"cell_type": "markdown",
|
| 729 |
+
"id": "dda5169b",
|
| 730 |
+
"metadata": {},
|
| 731 |
+
"source": [
|
| 732 |
+
"### Submission\n",
|
| 733 |
+
"\n",
|
| 734 |
+
"You do not have to submit your training notebook (you can if you would like to). For resource-efficiency and reliability reasons, we encourage you to upload your trained model weights (if you have one) attached to your submission notebook, instead of submitting your entire training process. For help with submitting model weight files, refer to section 5 in the Bohrium Guide. Your submission notebook only has to include the test inference section below.\n",
|
| 735 |
+
"\n",
|
| 736 |
+
"You need to save your answers to testset A and testset B in separate `jsonl` files, `clues_a.jsonl` and `clues_b.jsonl`, as shown below. `clues_a` and `clues_b` should be lists of clues (each clue being a list of lists of integers). You need to zip the files together into `submission.zip`. The file names are important. You must follow the naming conventions otherwise the evaluation script will not be able to find your answers."
|
| 737 |
+
]
|
| 738 |
+
},
|
| 739 |
+
{
|
| 740 |
+
"cell_type": "code",
|
| 741 |
+
"execution_count": null,
|
| 742 |
+
"id": "3582fdfe",
|
| 743 |
+
"metadata": {},
|
| 744 |
+
"outputs": [],
|
| 745 |
+
"source": [
|
| 746 |
+
"clue_giver = ClueGiver() # Initialize your model. You can load model weights here."
|
| 747 |
+
]
|
| 748 |
+
},
|
| 749 |
+
{
|
| 750 |
+
"cell_type": "code",
|
| 751 |
+
"execution_count": null,
|
| 752 |
+
"id": "e35c1193",
|
| 753 |
+
"metadata": {},
|
| 754 |
+
"outputs": [],
|
| 755 |
+
"source": [
|
| 756 |
+
"import os\n",
|
| 757 |
+
"if os.environ.get('DATA_PATH'):\n",
|
| 758 |
+
" TEST_PATH = os.environ.get(\"DATA_PATH\") + \"/\" \n",
|
| 759 |
+
"else:\n",
|
| 760 |
+
" TEST_PATH = \"/bohr/test-66r2/v1/\" # Fallback for local testing\n",
|
| 761 |
+
"\n",
|
| 762 |
+
"testset_a = load_from_disk(os.path.join(TEST_PATH, \"test/test_a\"))[\"test\"]\n",
|
| 763 |
+
"testset_b = load_from_disk(os.path.join(TEST_PATH, \"test/test_b\"))[\"test\"]\n",
|
| 764 |
+
"clues_a = clue_giver.construct_clues([x['label'] for x in testset_a], [x['options'] for x in testset_a])\n",
|
| 765 |
+
"clues_b = clue_giver.construct_clues([x['label'] for x in testset_b], [x['options'] for x in testset_b])"
|
| 766 |
+
]
|
| 767 |
+
},
|
| 768 |
+
{
|
| 769 |
+
"cell_type": "code",
|
| 770 |
+
"execution_count": null,
|
| 771 |
+
"id": "4ef60d7a",
|
| 772 |
+
"metadata": {},
|
| 773 |
+
"outputs": [],
|
| 774 |
+
"source": [
|
| 775 |
+
"import zipfile\n",
|
| 776 |
+
"import json\n",
|
| 777 |
+
"\n",
|
| 778 |
+
"def write_clues(clues: List[List[List[int]]], path: str):\n",
|
| 779 |
+
" with open(path, 'w') as f:\n",
|
| 780 |
+
" for c in clues:\n",
|
| 781 |
+
" f.write(json.dumps(c) + '\\n')\n",
|
| 782 |
+
"\n",
|
| 783 |
+
"write_clues(clues_a, \"clues_a.jsonl\")\n",
|
| 784 |
+
"write_clues(clues_b, \"clues_b.jsonl\")\n",
|
| 785 |
+
"\n",
|
| 786 |
+
"with zipfile.ZipFile('submission.zip', 'w') as zipf:\n",
|
| 787 |
+
" zipf.write('clues_a.jsonl')\n",
|
| 788 |
+
" zipf.write('clues_b.jsonl')"
|
| 789 |
+
]
|
| 790 |
+
},
|
| 791 |
+
{
|
| 792 |
+
"cell_type": "code",
|
| 793 |
+
"execution_count": null,
|
| 794 |
+
"id": "515d63b6-19d5-425f-85d6-d6ea9471047f",
|
| 795 |
+
"metadata": {},
|
| 796 |
+
"outputs": [],
|
| 797 |
+
"source": [
|
| 798 |
+
"import torch\n",
|
| 799 |
+
"\n",
|
| 800 |
+
"del clue_giver\n",
|
| 801 |
+
"torch.cuda.empty_cache()"
|
| 802 |
+
]
|
| 803 |
+
}
|
| 804 |
+
],
|
| 805 |
+
"metadata": {
|
| 806 |
+
"kernelspec": {
|
| 807 |
+
"display_name": "Python 3 (ipykernel)",
|
| 808 |
+
"language": "python",
|
| 809 |
+
"name": "python3"
|
| 810 |
+
},
|
| 811 |
+
"language_info": {
|
| 812 |
+
"codemirror_mode": {
|
| 813 |
+
"name": "ipython",
|
| 814 |
+
"version": 3
|
| 815 |
+
},
|
| 816 |
+
"file_extension": ".py",
|
| 817 |
+
"mimetype": "text/x-python",
|
| 818 |
+
"name": "python",
|
| 819 |
+
"nbconvert_exporter": "python",
|
| 820 |
+
"pygments_lexer": "ipython3",
|
| 821 |
+
"version": "3.12.9"
|
| 822 |
+
}
|
| 823 |
+
},
|
| 824 |
+
"nbformat": 4,
|
| 825 |
+
"nbformat_minor": 5
|
| 826 |
+
}
|
benchmark/IOAI/IOAI2025/Individual-Contest/Concepts/llm_proxy_tutorial.ipynb
ADDED
|
@@ -0,0 +1,263 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cells": [
|
| 3 |
+
{
|
| 4 |
+
"cell_type": "markdown",
|
| 5 |
+
"id": "1d983d23",
|
| 6 |
+
"metadata": {},
|
| 7 |
+
"source": [
|
| 8 |
+
"# This is a tutorial on how to use IOAI's provided LLM proxy"
|
| 9 |
+
]
|
| 10 |
+
},
|
| 11 |
+
{
|
| 12 |
+
"cell_type": "markdown",
|
| 13 |
+
"id": "f5033564",
|
| 14 |
+
"metadata": {},
|
| 15 |
+
"source": [
|
| 16 |
+
"## Step 1: initialize your OpenAI client\n",
|
| 17 |
+
"\n",
|
| 18 |
+
"Please use your provided api key here."
|
| 19 |
+
]
|
| 20 |
+
},
|
| 21 |
+
{
|
| 22 |
+
"cell_type": "code",
|
| 23 |
+
"execution_count": null,
|
| 24 |
+
"id": "699ae2b2",
|
| 25 |
+
"metadata": {},
|
| 26 |
+
"outputs": [],
|
| 27 |
+
"source": [
|
| 28 |
+
"from openai import AsyncClient\n",
|
| 29 |
+
"\n",
|
| 30 |
+
"BASE_URL = \"https://ioai-llm-proxy.up.railway.app/prox/v1\"\n",
|
| 31 |
+
"API_KEY = \"<YOUR_IOAI_API_KEY>\"\n",
|
| 32 |
+
"\n",
|
| 33 |
+
"openai_client = AsyncClient(\n",
|
| 34 |
+
" base_url=BASE_URL,\n",
|
| 35 |
+
" api_key=API_KEY,\n",
|
| 36 |
+
")"
|
| 37 |
+
]
|
| 38 |
+
},
|
| 39 |
+
{
|
| 40 |
+
"cell_type": "markdown",
|
| 41 |
+
"id": "8f2b8e77",
|
| 42 |
+
"metadata": {},
|
| 43 |
+
"source": [
|
| 44 |
+
"## Step 2: Generate output\n",
|
| 45 |
+
"\n",
|
| 46 |
+
"Note that we have an allowlist on model ids:\n",
|
| 47 |
+
"\n",
|
| 48 |
+
"- `openai/gpt-4.1`\n",
|
| 49 |
+
"- `openai/gpt-4.1-mini`\n",
|
| 50 |
+
"- `openai/gpt-4.1-nano`\n",
|
| 51 |
+
"- `openai/gpt-4o`\n",
|
| 52 |
+
"- `openai/gpt-4o-mini`\n",
|
| 53 |
+
"- `gpt-4o-mini`\n",
|
| 54 |
+
"- `gpt-4o`\n",
|
| 55 |
+
"- `gpt-4.1`\n",
|
| 56 |
+
"- `gpt-4.1-mini`\n",
|
| 57 |
+
"- `gpt-4.1-nano`\n",
|
| 58 |
+
"- `google/gemini-2.5-pro`\n",
|
| 59 |
+
"- `google/gemini-2.5-flash`\n",
|
| 60 |
+
"- `moonshotai/kimi-k2`\n",
|
| 61 |
+
"- `qwen/qwen3-235b-a22b-07-25`\n",
|
| 62 |
+
"- `anthropic/claude-sonnet-4`"
|
| 63 |
+
]
|
| 64 |
+
},
|
| 65 |
+
{
|
| 66 |
+
"cell_type": "code",
|
| 67 |
+
"execution_count": null,
|
| 68 |
+
"id": "96895459",
|
| 69 |
+
"metadata": {},
|
| 70 |
+
"outputs": [],
|
| 71 |
+
"source": [
|
| 72 |
+
"response = await openai_client.chat.completions.create(\n",
|
| 73 |
+
" model=\"openai/gpt-4o-mini\",\n",
|
| 74 |
+
" messages=[{\"role\": \"user\", \"content\": \"Hello, world!\"}],\n",
|
| 75 |
+
")\n",
|
| 76 |
+
"\n",
|
| 77 |
+
"print(response)\n",
|
| 78 |
+
"print(response.choices[0].message.content)"
|
| 79 |
+
]
|
| 80 |
+
},
|
| 81 |
+
{
|
| 82 |
+
"cell_type": "markdown",
|
| 83 |
+
"id": "6c0b2e3e",
|
| 84 |
+
"metadata": {},
|
| 85 |
+
"source": [
|
| 86 |
+
"## Advanced: Structured Outputs\n",
|
| 87 |
+
"\n",
|
| 88 |
+
"You can use structured outputs to generate objects that fit a specific structure."
|
| 89 |
+
]
|
| 90 |
+
},
|
| 91 |
+
{
|
| 92 |
+
"cell_type": "code",
|
| 93 |
+
"execution_count": null,
|
| 94 |
+
"id": "4f67373b",
|
| 95 |
+
"metadata": {},
|
| 96 |
+
"outputs": [],
|
| 97 |
+
"source": [
|
| 98 |
+
"from pydantic import BaseModel\n",
|
| 99 |
+
"from rich import print as rprint\n",
|
| 100 |
+
"\n",
|
| 101 |
+
"class CalendarItem(BaseModel):\n",
|
| 102 |
+
" title: str\n",
|
| 103 |
+
" month: int\n",
|
| 104 |
+
" date: int\n",
|
| 105 |
+
" year: int\n",
|
| 106 |
+
" description: str\n",
|
| 107 |
+
"\n",
|
| 108 |
+
"result = await openai_client.beta.chat.completions.parse(\n",
|
| 109 |
+
" model=\"openai/gpt-4o-mini\",\n",
|
| 110 |
+
" messages=[\n",
|
| 111 |
+
" {\"role\": \"system\", \"content\": \"You are a helpful assistant that generates calendar items.\"},\n",
|
| 112 |
+
" {\"role\": \"user\", \"content\": \"IOAI opening ceremony at Aug. 1, 2025\"}\n",
|
| 113 |
+
" ],\n",
|
| 114 |
+
" response_format=CalendarItem,\n",
|
| 115 |
+
")\n",
|
| 116 |
+
"\n",
|
| 117 |
+
"print(result)\n",
|
| 118 |
+
"rprint(result.choices[0].message.parsed)"
|
| 119 |
+
]
|
| 120 |
+
},
|
| 121 |
+
{
|
| 122 |
+
"cell_type": "markdown",
|
| 123 |
+
"id": "d1d6dafa",
|
| 124 |
+
"metadata": {},
|
| 125 |
+
"source": [
|
| 126 |
+
"## Batch requests with retry\n",
|
| 127 |
+
"\n",
|
| 128 |
+
"To generate large amounts of LLM completions efficiently and rhobustly, we can leverage:\n",
|
| 129 |
+
"\n",
|
| 130 |
+
"- Concurrent requests capped by an async Semaphore -- so that we can make multiple requests at the same time without overwhelming our bandwidth\n",
|
| 131 |
+
"- Exponential backoff based retry for each request -- so that we gracefully retry when unexpected network / provider errors happen\n",
|
| 132 |
+
"\n",
|
| 133 |
+
"The below is an example:"
|
| 134 |
+
]
|
| 135 |
+
},
|
| 136 |
+
{
|
| 137 |
+
"cell_type": "code",
|
| 138 |
+
"execution_count": null,
|
| 139 |
+
"id": "f591a91f",
|
| 140 |
+
"metadata": {},
|
| 141 |
+
"outputs": [],
|
| 142 |
+
"source": [
|
| 143 |
+
"class RankingExtraction(BaseModel):\n",
|
| 144 |
+
" ranking: int\n",
|
| 145 |
+
" contest: str\n",
|
| 146 |
+
"\n",
|
| 147 |
+
"texts = [f\"We ranked {i}th in the IOAI 2025\" for i in range(1, 101)]\n",
|
| 148 |
+
"len(texts)"
|
| 149 |
+
]
|
| 150 |
+
},
|
| 151 |
+
{
|
| 152 |
+
"cell_type": "code",
|
| 153 |
+
"execution_count": null,
|
| 154 |
+
"id": "80f7dafa",
|
| 155 |
+
"metadata": {},
|
| 156 |
+
"outputs": [],
|
| 157 |
+
"source": [
|
| 158 |
+
"from typing import List\n",
|
| 159 |
+
"from tenacity import retry, stop_after_attempt, wait_exponential\n",
|
| 160 |
+
"from asyncio import Semaphore\n",
|
| 161 |
+
"from tqdm.notebook import tqdm\n",
|
| 162 |
+
"from tqdm.asyncio import tqdm as tqdm_asyncio\n",
|
| 163 |
+
"\n",
|
| 164 |
+
"@retry(\n",
|
| 165 |
+
" stop=stop_after_attempt(3),\n",
|
| 166 |
+
" wait=wait_exponential(multiplier=1, min=4, max=10),\n",
|
| 167 |
+
")\n",
|
| 168 |
+
"async def process_one(txt: str) -> RankingExtraction:\n",
|
| 169 |
+
" result = await openai_client.beta.chat.completions.parse(\n",
|
| 170 |
+
" model=\"openai/gpt-4o-mini\",\n",
|
| 171 |
+
" messages=[{\"role\": \"user\", \"content\": txt}],\n",
|
| 172 |
+
" response_format=RankingExtraction,\n",
|
| 173 |
+
" )\n",
|
| 174 |
+
" return result.choices[0].message.parsed"
|
| 175 |
+
]
|
| 176 |
+
},
|
| 177 |
+
{
|
| 178 |
+
"cell_type": "code",
|
| 179 |
+
"execution_count": null,
|
| 180 |
+
"id": "13380165",
|
| 181 |
+
"metadata": {},
|
| 182 |
+
"outputs": [],
|
| 183 |
+
"source": [
|
| 184 |
+
"print(texts[0])\n",
|
| 185 |
+
"print(await process_one(texts[0]))"
|
| 186 |
+
]
|
| 187 |
+
},
|
| 188 |
+
{
|
| 189 |
+
"cell_type": "code",
|
| 190 |
+
"execution_count": null,
|
| 191 |
+
"id": "be960117",
|
| 192 |
+
"metadata": {},
|
| 193 |
+
"outputs": [],
|
| 194 |
+
"source": [
|
| 195 |
+
"async def process_all(texts: List[str]):\n",
|
| 196 |
+
" semaphore = Semaphore(50) # we limit to making 50 requests concurrently\n",
|
| 197 |
+
" async def _process_with_sema(txt: str):\n",
|
| 198 |
+
" async with semaphore:\n",
|
| 199 |
+
" return await process_one(txt)\n",
|
| 200 |
+
" return await tqdm_asyncio.gather(\n",
|
| 201 |
+
" *[_process_with_sema(txt) for txt in texts],\n",
|
| 202 |
+
" desc=\"Processing\",\n",
|
| 203 |
+
" total=len(texts),\n",
|
| 204 |
+
" )\n",
|
| 205 |
+
"\n",
|
| 206 |
+
"results = await process_all(texts)\n",
|
| 207 |
+
"\n",
|
| 208 |
+
"results[:10]"
|
| 209 |
+
]
|
| 210 |
+
},
|
| 211 |
+
{
|
| 212 |
+
"cell_type": "markdown",
|
| 213 |
+
"id": "80bee95e",
|
| 214 |
+
"metadata": {},
|
| 215 |
+
"source": [
|
| 216 |
+
"# Check your credits\n",
|
| 217 |
+
"\n",
|
| 218 |
+
"You get $10 of credits, so use it economically! You can run the following cell to check the amount of credits you have used."
|
| 219 |
+
]
|
| 220 |
+
},
|
| 221 |
+
{
|
| 222 |
+
"cell_type": "code",
|
| 223 |
+
"execution_count": null,
|
| 224 |
+
"id": "81d2e662",
|
| 225 |
+
"metadata": {},
|
| 226 |
+
"outputs": [],
|
| 227 |
+
"source": [
|
| 228 |
+
"from httpx import get\n",
|
| 229 |
+
"\n",
|
| 230 |
+
"result = get(f\"https://ioai-llm-proxy.up.railway.app/credits/{API_KEY}\")\n",
|
| 231 |
+
"\n",
|
| 232 |
+
"resp = result.json()\n",
|
| 233 |
+
"\n",
|
| 234 |
+
"print(f\"\"\"\n",
|
| 235 |
+
"Credits limit: ${resp['limit']}\n",
|
| 236 |
+
"Used: ${resp['usage']}\n",
|
| 237 |
+
"Credits remaining: ${resp['limit'] - resp['usage']}\n",
|
| 238 |
+
"\"\"\")"
|
| 239 |
+
]
|
| 240 |
+
}
|
| 241 |
+
],
|
| 242 |
+
"metadata": {
|
| 243 |
+
"kernelspec": {
|
| 244 |
+
"display_name": ".venv",
|
| 245 |
+
"language": "python",
|
| 246 |
+
"name": "python3"
|
| 247 |
+
},
|
| 248 |
+
"language_info": {
|
| 249 |
+
"codemirror_mode": {
|
| 250 |
+
"name": "ipython",
|
| 251 |
+
"version": 3
|
| 252 |
+
},
|
| 253 |
+
"file_extension": ".py",
|
| 254 |
+
"mimetype": "text/x-python",
|
| 255 |
+
"name": "python",
|
| 256 |
+
"nbconvert_exporter": "python",
|
| 257 |
+
"pygments_lexer": "ipython3",
|
| 258 |
+
"version": "3.12.11"
|
| 259 |
+
}
|
| 260 |
+
},
|
| 261 |
+
"nbformat": 4,
|
| 262 |
+
"nbformat_minor": 5
|
| 263 |
+
}
|
benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v12.json
ADDED
|
@@ -0,0 +1,57 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"schema_version": "ioling_train_expansion_v12",
|
| 3 |
+
"reviewed_at_utc": "2026-07-11",
|
| 4 |
+
"review_method": "Every prompt, target, answer, spelling, and derivation was checked directly against the rendered official English problem and solution pages.",
|
| 5 |
+
"sources": [
|
| 6 |
+
{
|
| 7 |
+
"source_problem_id": "2022-individual-1",
|
| 8 |
+
"year": 2022,
|
| 9 |
+
"title": "Ubykh",
|
| 10 |
+
"problem_pdf_page_1_indexed": 1,
|
| 11 |
+
"solution_pdf_page_1_indexed": 1,
|
| 12 |
+
"problem_body": "Problem 1 (20 points). Here are some forms of the Ubykh verb 'to give' and their English translations:\n\n1. wəšʼtʷən — we give you(sg) to him\n2. sawtʷən — you(sg) give me to them\n3. awəstʷan — I give them to you(sg)\n4. wəsənatʷən — they give you(sg) to me\n5. ŝʷəstʷan — I give you(pl) to him\n6. šʼantʷan — he gives us to them\n7. awəšʼtʷən — we give him to you(sg)\n8. səŝʷəntʷan — he gives me to you(pl)\n9. aŝʷəstʷan — I give him to you(pl)\n\n(a) The last form can be translated in two ways. What is its other translation?\n\n(b) Translate into English:\n10. ašʼəntʷən\n11. səŝʷtʷan\n12. šʼəwənatʷan\n\n(c) Translate into Ubykh:\n13. they give you(pl) to me\n14. you(pl) give him to me\n15. you(sg) give us to him\n16. we give you(sg) to them\n17. he gives them to us\n\nə is a vowel; šʼ, ŝʷ, tʷ are consonants.",
|
| 13 |
+
"checked_rules": [
|
| 14 |
+
"Person prefixes identify the direct object, indirect object, and subject in that order around the fixed verb stem tʷ.",
|
| 15 |
+
"s-, šʼ-, w-, and ŝʷ- mark first singular, first plural, second singular, and second plural participants; third person uses a-, n-, na-, or zero according to role and number.",
|
| 16 |
+
"The vowel is a when the direct object is plural or a second-person-plural participant is present; otherwise it is ə. Schwa separates adjacent consonants."
|
| 17 |
+
],
|
| 18 |
+
"tasks": [
|
| 19 |
+
{"subpart":"a","id":"a.1","target":"Give the other English translation of aŝʷəstʷan.","answer":"I give them to you(pl).","accepted_values":["I give them to you (pl).","I give them to you (plural).","I give them to youpl."],"reasoning":"The prefix sequence can mark third-person plural as direct object and second-person plural as indirect object, while the subject is first-person singular. Thus the other reading is 'I give them to you(pl).'"},
|
| 20 |
+
{"subpart":"b","id":"b.1","target":"Translate ašʼəntʷən into English.","answer":"he gives him to us","reasoning":"The prefixes identify a third-person singular direct object, first-person plural indirect object, and third-person singular subject, giving 'he gives him to us'."},
|
| 21 |
+
{"subpart":"b","id":"b.2","target":"Translate səŝʷtʷan into English.","answer":"you(pl) give me to him","accepted_values":["you (pl) give me to him","you (plural) give me to him","youpl give me to him"],"reasoning":"s- marks me as direct object, ŝʷ- marks a second-person-plural subject, and the remaining third-person singular participant is the indirect object."},
|
| 22 |
+
{"subpart":"b","id":"b.3","target":"Translate šʼəwənatʷan into English.","answer":"they give us to you(sg)","accepted_values":["they give us to you (sg)","they give us to you (singular)","they give us to yousg"],"reasoning":"šʼ- marks us as direct object, w- marks you singular as indirect object, and na- marks the third-person-plural subject."},
|
| 23 |
+
{"subpart":"c","id":"c.1","target":"Translate 'they give you(pl) to me' into Ubykh.","answer":"ŝʷəsənatʷan","reasoning":"Use ŝʷ- for the second-person-plural direct object, s- for the first-person-singular indirect object, and na- for the plural subject: ŝʷəsənatʷan."},
|
| 24 |
+
{"subpart":"c","id":"c.2","target":"Translate 'you(pl) give him to me' into Ubykh.","answer":"asəŝʷtʷan","reasoning":"Combine third-person-singular direct object a-, first-person-singular indirect object s-, and second-person-plural subject ŝʷ-, inserting schwa between consonants."},
|
| 25 |
+
{"subpart":"c","id":"c.3","target":"Translate 'you(sg) give us to him' into Ubykh.","answer":"šʼəwtʷan","reasoning":"Use šʼ- for first-person-plural direct object and w- for the second-person-singular subject; the third-person-singular indirect object is unmarked."},
|
| 26 |
+
{"subpart":"c","id":"c.4","target":"Translate 'we give you(sg) to them' into Ubykh.","answer":"wašʼtʷən","reasoning":"Use w- for the second-person-singular direct object, a- for the third-person-plural indirect object, and šʼ- for the first-person-plural subject."},
|
| 27 |
+
{"subpart":"c","id":"c.5","target":"Translate 'he gives them to us' into Ubykh.","answer":"ašʼəntʷan","reasoning":"Use a- for the third-person-plural direct object, šʼ- for the first-person-plural indirect object, and n- for the third-person-singular subject."}
|
| 28 |
+
]
|
| 29 |
+
},
|
| 30 |
+
{
|
| 31 |
+
"source_problem_id": "2024-individual-1",
|
| 32 |
+
"year": 2024,
|
| 33 |
+
"title": "Koryak",
|
| 34 |
+
"problem_pdf_page_1_indexed": 1,
|
| 35 |
+
"solution_pdf_page_1_indexed": 1,
|
| 36 |
+
"problem_body": "Problem 1 (20 points). Here are some verb forms in Koryak and their English translations:\n\n1. təjekmiņŋənet — I will catch them(du)\n2. kekmiņŋənew — you(sg) catch them(pl)\n3. mətəlhun — we(du) saw him\n4. kujguŋnet — you(sg) bite them(du)\n5. kinuheņŋətək — you(du) wait for me\n6. nekmitən — they caught him\n7. mətkolholaŋən — we(pl) see him\n8. mətuhennet — we(du) waited for them(du)\n9. enanŋevlatək — you(pl) sent me\n10. tuhettək — I waited for you(du)\n11. məccuheņŋətək — we(du) will wait for you(du)\n12. inekmittək — you(du) caught me\n13. təjelleŋən — I will lead him\n14. nekulhuŋnew — they see them(pl)\n15. najalholaŋtək — they will see you(pl)\n16. məccenŋivŋənew — we(du) will send them(pl)\n17. nejenŋivŋənet — they will send them(du)\n18. məccallalaŋtək — we(du) will lead you(pl); we(pl) will lead you(pl); we(pl) will lead you(du)\n\n(a) Translate into English:\n19. kulleŋən\n20. jinejguŋtək\n21. tekminnew\n22. təjohallaŋtək\n23. mətkonŋevlaŋən\n\n(b) Translate into Koryak:\n24. you(sg) will see them(du)\n25. we(pl) bit him\n26. you(pl) catch me\n27. they send you(du)\n28. you(du) led me\n\n(sg) is one person, (du) two people, and (pl) three or more people. ə is a vowel; c, g, j, ņ, ŋ, h, and w are consonants.",
|
| 37 |
+
"checked_rules": [
|
| 38 |
+
"Verb order is subject prefix, optional ə, tense prefix, optional ine- for a first-person-singular object, root, optional -la, tense suffix, optional ə, and person/number ending.",
|
| 39 |
+
"Subject prefixes are t- first singular, mət- first dual/plural, zero second singular, and ne- third dual/plural; ku- is present, je- future, and past is unmarked.",
|
| 40 |
+
"Object endings are -tək second dual/plural, -n third singular, -net third dual, and -new third plural; -la marks first/second plural participation.",
|
| 41 |
+
"Schwa breaks prohibited consonant clusters; prefix vowels delete before vowels; t+j becomes cc, t+l becomes ll, t+n becomes nn, and t+ŋ becomes ņŋ; a triggers vowel harmony."
|
| 42 |
+
],
|
| 43 |
+
"tasks": [
|
| 44 |
+
{"subpart":"a","id":"a.1","target":"Translate kulleŋən into English.","answer":"you(sg) lead him","accepted_values":["you (sg) lead him","you (singular) lead him","yousg lead him"],"reasoning":"The subject is unmarked second-person singular, ku- is present, lle is 'lead', -ŋ marks present, and -n marks a third-person-singular object."},
|
| 45 |
+
{"subpart":"a","id":"a.2","target":"Translate jinejguŋtək into English.","answer":"you(du) will bite me","accepted_values":["you (du) will bite me","you (dual) will bite me","you two will bite me","youdu will bite me"],"reasoning":"je- marks future, ine- marks a first-person-singular object, jgu is 'bite', and -tək identifies a second-person-dual/plural subject; here it is dual."},
|
| 46 |
+
{"subpart":"a","id":"a.3","target":"Translate tekminnew into English.","answer":"I caught them(pl)","accepted_values":["I caught them (pl)","I caught them (plural)","I caught thempl"],"reasoning":"t- marks first-person-singular subject, the absent tense prefix makes the form past, ekmi is 'catch', and -new marks a third-person-plural object."},
|
| 47 |
+
{"subpart":"a","id":"a.4","target":"Translate təjohallaŋtək into English.","answer":"I will wait for you(pl)","accepted_values":["I will wait for you (pl)","I will wait for you (plural)","I will wait for youpl"],"reasoning":"t- marks 'I', je- marks future, the harmonized root is 'wait', -la marks plural participation, and -tək marks a second-person-plural object."},
|
| 48 |
+
{"subpart":"a","id":"a.5","target":"Translate mətkonŋevlaŋən into English.","answer":"we(pl) send him","accepted_values":["we (pl) send him","we (plural) send him","wepl send him"],"reasoning":"mət- marks a first-person dual/plural subject, ku- is present, nŋiv is 'send', -la selects the plural reading, and -n marks 'him'."},
|
| 49 |
+
{"subpart":"b","id":"b.1","target":"Translate 'you(sg) will see them(du)' into Koryak.","answer":"jelhuŋnet","reasoning":"Use zero second-person-singular subject, future je-, root lhu 'see', present/future -ŋ, and dual third-person object -net: jelhuŋnet."},
|
| 50 |
+
{"subpart":"b","id":"b.2","target":"Translate 'we(pl) bit him' into Koryak.","answer":"mətəjgolan","reasoning":"Use mət- for first-person plural, no tense prefix for past, root jgu 'bite', plural -la, and singular object -n; harmony and cluster repair give mətəjgolan."},
|
| 51 |
+
{"subpart":"b","id":"b.3","target":"Translate 'you(pl) catch me' into Koryak.","answer":"kenakmellaŋtək","reasoning":"Present ku-, first-person object ine-, root ekmi 'catch', plural -la, and second-person plural -tək undergo vowel deletion and harmony, yielding kenakmellaŋtək."},
|
| 52 |
+
{"subpart":"b","id":"b.4","target":"Translate 'they send you(du)' into Koryak.","answer":"nekunŋivŋətək","reasoning":"Combine third-person-plural subject ne-, present ku-, root nŋiv 'send', present -ŋ, and second-person-dual object -tək; cluster repair yields nekunŋivŋətək."},
|
| 53 |
+
{"subpart":"b","id":"b.5","target":"Translate 'you(du) led me' into Koryak.","answer":"inelletək","reasoning":"Past tense is unmarked; ine- marks the first-person-singular object, lle is 'lead', and -tək marks a second-person-dual subject, giving inelletək."}
|
| 54 |
+
]
|
| 55 |
+
}
|
| 56 |
+
]
|
| 57 |
+
}
|
benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v13.json
ADDED
|
@@ -0,0 +1,31 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"schema_version": "ioling_train_expansion_v13",
|
| 3 |
+
"reviewed_at_utc": "2026-07-12",
|
| 4 |
+
"review_method": "Problem text, target text, spelling, canonical answers, accepted aliases, and derivations were compared directly with rendered page 2 of the official 2017 English problem and solution PDFs.",
|
| 5 |
+
"sources": [
|
| 6 |
+
{
|
| 7 |
+
"source_problem_id": "2017-individual-2",
|
| 8 |
+
"year": 2017,
|
| 9 |
+
"title": "Abui",
|
| 10 |
+
"problem_pdf_page_1_indexed": 2,
|
| 11 |
+
"solution_pdf_page_1_indexed": 2,
|
| 12 |
+
"problem_body": "Problem 2 (20 points). Here are some words and word combinations in Abui and their English translations in arbitrary order:\n\n1. abang\n2. atáng heya\n3. bataa hawata\n4. dekafi\n5. ebataa hatáng\n6. ekuda hawata\n7. falepak hawei\n8. hatáng hamin\n9. helui\n10. maama hefalepak\n11. napong\n12. rièng\n13. ritama\n14. riya hatáng\n15. tama habang\n16. tamin\n17. tefe hawei\n\na. his fingertip\nb. your (sg.) branch\nc. my face\nd. one's own rope\ne. your (sg.) shoulder\nf. your (pl.) mother's hand\ng. our pigs' ears (the ear of the pig of each of us)\nh. father's pistol\ni. your (sg.) horse's neck\nj. trigger\nk. your (pl.) eyes\nl. our noses (the nose of each of us)\nm. his knife\nn. seashore\no. upper part of a tree\np. your (sg.) thumb\nq. your (pl.) sea\n\n(a) Determine the correct correspondences.\n\n(b) Translate into English:\n1. amin\n2. deya hebataa\n\n(c) Translate into Abui:\n1. pig\n2. your (pl.) knife\n3. your (sg.) mother's father\n4. my father's face\n5. one's own ear\n6. my sea\n\nThe marks acute and grave denote tones.",
|
| 13 |
+
"checked_rules": [
|
| 14 |
+
"A possessor precedes the possessed noun.",
|
| 15 |
+
"Possessor prefixes are n- for first-person singular, zero for second-person singular, h- for third-person singular, t- for 'of each of us', d- for one's own, and ri- for second-person plural.",
|
| 16 |
+
"Except after ri-, the possessed noun takes a- if it is a body part and e- otherwise.",
|
| 17 |
+
"The vocabulary recoverable from the matches includes fe 'pig', lui 'knife', ya 'mother', maama 'father', pong 'face', wei 'ear', and tama 'sea'."
|
| 18 |
+
],
|
| 19 |
+
"tasks": [
|
| 20 |
+
{"subpart":"b","id":"b.1","target":"Translate amin into English.","answer":"your (sg.) nose","accepted_values":["your (sg) nose","your (singular) nose"],"reasoning":"min is 'nose', a body part. A second-person-singular possessor has no prefix, and a possessed body part takes a-, so a-min means 'your (sg.) nose'."},
|
| 21 |
+
{"subpart":"b","id":"b.2","target":"Translate deya hebataa into English.","answer":"one's own mother's tree","accepted_values":["one’s own mother’s tree","one's own mother's tree."],"reasoning":"d-e-ya is 'one's own mother': d- marks one's own and e- marks a non-body-part possession. The mother is then the third-person possessor of e-bataa 'tree', giving 'one's own mother's tree'."},
|
| 22 |
+
{"subpart":"c","id":"c.1","target":"Translate 'pig' into Abui.","answer":"fe","reasoning":"The matched form te-fe ha-wei means 'our pigs' ears', so the noun root for 'pig' is fe."},
|
| 23 |
+
{"subpart":"c","id":"c.2","target":"Translate 'your (pl.) knife' into Abui.","answer":"ri-lui","accepted_values":["rilui"],"reasoning":"lui is 'knife' and ri- marks a second-person-plural possessor, so the form is ri-lui."},
|
| 24 |
+
{"subpart":"c","id":"c.3","target":"Translate 'your (sg.) mother's father' into Abui.","answer":"e-ya he-maama","accepted_values":["eya hemaama"],"reasoning":"A second-person-singular possessor is unmarked, and mother is not a body part, giving e-ya. That mother is a third-person possessor of father, also not a body part, giving he-maama."},
|
| 25 |
+
{"subpart":"c","id":"c.4","target":"Translate 'my father's face' into Abui.","answer":"ne-maama ha-pong","accepted_values":["nemaama hapong"],"reasoning":"My father is n-e-maama, contracted to ne-maama. Father then possesses the body part face, so h-a-pong gives ha-pong."},
|
| 26 |
+
{"subpart":"c","id":"c.5","target":"Translate 'one's own ear' into Abui.","answer":"da-wei","accepted_values":["dawei"],"reasoning":"d- marks one's own and ear is a body part, which takes a-, so d-a-wei contracts to da-wei."},
|
| 27 |
+
{"subpart":"c","id":"c.6","target":"Translate 'my sea' into Abui.","answer":"ne-tama","accepted_values":["netama"],"reasoning":"n- marks a first-person-singular possessor and sea is not a body part, so n-e-tama contracts to ne-tama."}
|
| 28 |
+
]
|
| 29 |
+
}
|
| 30 |
+
]
|
| 31 |
+
}
|
benchmark/IOL/ioling_hf/data/manual_overrides/train_expansion_v14.json
ADDED
|
@@ -0,0 +1,90 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"schema_version": "ioling_train_expansion_v14",
|
| 3 |
+
"reviewed_at_utc": "2026-07-12",
|
| 4 |
+
"review_method": "Every example, requested item, tone or segment mark, canonical answer, accepted alternative, and rule was compared directly with rendered official English problem and solution pages.",
|
| 5 |
+
"sources": [
|
| 6 |
+
{
|
| 7 |
+
"source_problem_id": "2017-individual-3",
|
| 8 |
+
"year": 2017,
|
| 9 |
+
"title": "Kimbundu",
|
| 10 |
+
"problem_pdf_page_1_indexed": 3,
|
| 11 |
+
"solution_pdf_page_1_indexed": 3,
|
| 12 |
+
"problem_body": "Problem 3 (20 points). Here are some sentences in Kimbundu and their English translations:\n\n1. ŋgámónà dìhónʒò mùdìlóŋgà — I saw the banana on the plate.\n2. àlóʒí ásáŋgá djálà mùdìkúŋgù — The sorcerers met the man in the cave.\n3. ŋgádjà dìhónʒó djámì — I ate my banana.\n4. mùdjúlù mwálà ʒìtéténbwà — There are stars in the sky.\n5. dìkámbá djámí djáʃíkà nì djákínà — My friend sang and danced.\n6. ŋgámónà dìkúŋgú djámí — Did I see my cave?\n7. ŋgámóná málà mùkìtándà — I saw the men in the square.\n8. ŋgásáŋgá múlóʒí mwámì mùlwándà — I met my sorcerer in Luanda.\n9. mùkìtándà mwálá djálá djámì — My man (husband) is in the square.\n10. mùdìkúŋgù ŋgámónà màkòlómbóló — Did I see the roosters in the cave?\n11. àtú ádjà dìhónʒò mùlwándá — Did the people eat the banana in Luanda?\n\n(a) Translate into English:\n12. múlóʒí mwámónà ʒìtéténbwá\n13. ʒìtéténbwá ʒjálà mùdjúlù\n14. ŋgákínà\n15. djálá djámónà màhónʒò mùlwándá\n\n(b) Translate into Kimbundu:\n16. Did I sing?\n17. The person met the sorcerer and the friend in the square.\n18. My man (husband) saw the cave.\n19. There are sorcerers in Luanda.\n\nw = w in win. j = y in yum. ʃ and ʒ are consonants. Acute and grave marks indicate high and low tone.",
|
| 13 |
+
"checked_rules": [
|
| 14 |
+
"Basic order is subject, verb, optional object, optional place; first-person-singular subjects are expressed by the ŋg- verb prefix.",
|
| 15 |
+
"A place phrase may be fronted: X V L is equivalent to L V X. A possessed noun precedes its possessive pronoun.",
|
| 16 |
+
"Noun-class concord uses singular mú- or dì- and plural à-, má-, or ʒì-; place expressions use mù-.",
|
| 17 |
+
"The last tone of a word assimilates to the first tone of the following word. The sentence-final tone is low in statements and high in questions."
|
| 18 |
+
],
|
| 19 |
+
"tasks": [
|
| 20 |
+
{"subpart":"a","id":"a.1","target":"Translate item 12, 'múlóʒí mwámónà ʒìtéténbwá', into English.","answer":"Did the sorcerer see the stars?","reasoning":"múlóʒí is singular 'sorcerer', mwámónà is the concordant past verb 'saw', and ʒìtéténbwá is plural 'stars'. The final high tone marks a question."},
|
| 21 |
+
{"subpart":"a","id":"a.2","target":"Translate item 13, 'ʒìtéténbwá ʒjálà mùdjúlù', into English.","answer":"There are stars in the sky.","reasoning":"The plural noun-class forms ʒìtéténbwá 'stars' and ʒjálà 'are' combine with the place phrase mùdjúlù 'in the sky'."},
|
| 22 |
+
{"subpart":"a","id":"a.3","target":"Translate item 14, 'ŋgákínà', into English.","answer":"I danced.","reasoning":"ŋg- marks a first-person-singular subject and kínà is 'dance'; the final low tone makes the sentence declarative."},
|
| 23 |
+
{"subpart":"a","id":"a.4","target":"Translate item 15, 'djálá djámónà màhónʒò mùlwándá', into English.","answer":"Did the man see the bananas in Luanda?","reasoning":"djálá is 'man', the concordant djámónà is 'saw', màhónʒò is plural 'bananas', and mùlwándá is 'in Luanda'. The final high tone marks a question."},
|
| 24 |
+
{"subpart":"b","id":"b.1","target":"Translate item 16, 'Did I sing?', into Kimbundu.","answer":"ŋgáʃíká","reasoning":"Use ŋg- for the first-person-singular subject with the verb ʃík- 'sing', and put a high tone on the final syllable because the sentence is interrogative."},
|
| 25 |
+
{"subpart":"b","id":"b.2","target":"Translate item 17, 'The person met the sorcerer and the friend in the square.', into Kimbundu.","answer":"mútú mwásáŋgá múlóʒì nì dìkámbà mùkìtándà","reasoning":"Use singular mú-class concord for mútú 'person', mwásáŋgá 'met', and múlóʒì 'sorcerer'; coordinate dìkámbà 'friend' with nì and add mùkìtándà 'in the square'."},
|
| 26 |
+
{"subpart":"b","id":"b.3","target":"Translate item 18, 'My man (husband) saw the cave.', into Kimbundu.","answer":"djálá djámí djámónà dìkúŋgù","reasoning":"Place the possessed noun djálá before djámí 'my', use singular concord in djámónà 'saw', and use dìkúŋgù for 'cave'."},
|
| 27 |
+
{"subpart":"b","id":"b.4","target":"Translate item 19, 'There are sorcerers in Luanda.', into Kimbundu.","answer":"mùlwándà mwálà àlóʒì","accepted_values":["àlóʒí álà mùlwándà"],"reasoning":"With the place fronted, use mùlwándà mwálà àlóʒì. The equivalent unfronted order is àlóʒí álà mùlwánd��; both have plural à-class concord."}
|
| 28 |
+
]
|
| 29 |
+
},
|
| 30 |
+
{
|
| 31 |
+
"source_problem_id": "2018-individual-2",
|
| 32 |
+
"year": 2018,
|
| 33 |
+
"title": "Hakhun",
|
| 34 |
+
"problem_pdf_page_1_indexed": 2,
|
| 35 |
+
"solution_pdf_page_1_indexed": 1,
|
| 36 |
+
"problem_body": "Problem 2 (20 points). Here are some sentences in Hakhun and their English translations:\n\n1. ŋa ka kɤ ne — Do I go?\n2. nɤ ʒip tuʔ ne — Did you(sg) sleep?\n3. ŋabə ati lapkʰi tɤʔ ne — Did I see him?\n4. nirum kəmə nuʔrum cʰam ki ne — Do we know you(pl)?\n5. nɤbə ŋa lapkʰi rɤ ne — Do you(sg) see me?\n6. tarum kəmə nɤ lan tʰu ne — Did they beat you(sg)?\n7. nuʔrum kəmə ati lapkʰi kan ne — Do you(pl) see him?\n8. nɤbə ati cʰam tuʔ ne — Did you(sg) know him?\n9. tarum kəmə nirum lapkʰi ri ne — Do they see us?\n10. ati kəmə ŋa lapkʰi tʰɤ ne — Did he see me?\n\n(a) Translate into English:\n1. nɤ ʒip ku ne\n2. ati kəmə nirum lapkʰi tʰi ne\n3. tarum kəmə nuʔrum cʰam ran ne\n4. nirum kəmə tarum lan ki ne\n5. nirum kəmə nɤ cʰam tiʔ ne\n6. nirum ka tiʔ ne\n\n(b) Translate into Hakhun:\n7. Did I beat you(sg)?\n8. Did they see me?\n9. Does he know you(sg)?\n10. Do you(pl) sleep?\n\nə and ɤ are vowels. cʰ, kʰ, ŋ, tʰ, ʒ and ʔ are consonants.",
|
| 37 |
+
"checked_rules": [
|
| 38 |
+
"Order is subject, optional object, predicate, agreement complex, ne. First- and second-person singular transitive subjects take -bə; third-person and plural transitive subjects take kəmə.",
|
| 39 |
+
"The person hierarchy is first > second > third. If the subject outranks the object, past uses t-...-ʔ and present uses k-; if the object outranks the subject, past uses tʰ- and present uses r-.",
|
| 40 |
+
"The agreement suffix is -ɤ when first-person singular participates, -i when first-person plural participates, otherwise -u for second-person singular and -an for second-person plural.",
|
| 41 |
+
"The lexical predicates are ka 'go', ʒip 'sleep', lapkʰi 'see', cʰam 'know', and lan 'beat'."
|
| 42 |
+
],
|
| 43 |
+
"tasks": [
|
| 44 |
+
{"subpart":"a","id":"a.1","target":"Translate item 1, 'nɤ ʒip ku ne', into English.","answer":"Do you(sg) sleep?","accepted_values":["Do you (sg) sleep?","Do you (singular) sleep?"],"reasoning":"nɤ is second-person singular and ʒip is 'sleep'. Present k- plus the second-person-singular suffix -u gives ku."},
|
| 45 |
+
{"subpart":"a","id":"a.2","target":"Translate item 2, 'ati kəmə nirum lapkʰi tʰi ne', into English.","answer":"Did he see us?","reasoning":"ati is 'he' and nirum is 'us'. Since the first-person object outranks the third-person subject, past agreement uses tʰ- plus first-person-plural -i."},
|
| 46 |
+
{"subpart":"a","id":"a.3","target":"Translate item 3, 'tarum kəmə nuʔrum cʰam ran ne', into English.","answer":"Do they know you(pl)?","accepted_values":["Do they know you (pl)?","Do they know you (plural)?"],"reasoning":"tarum is 'they', nuʔrum is second-person plural, and cʰam is 'know'. The higher-ranked object triggers present r- with second-person-plural -an."},
|
| 47 |
+
{"subpart":"a","id":"a.4","target":"Translate item 4, 'nirum kəmə tarum lan ki ne', into English.","answer":"Do we beat them?","reasoning":"nirum is 'we', tarum is 'them', and lan is 'beat'. The first-person subject outranks the third-person object, giving present k- plus first-person-plural -i."},
|
| 48 |
+
{"subpart":"a","id":"a.5","target":"Translate item 5, 'nirum kəmə nɤ cʰam tiʔ ne', into English.","answer":"Did we know you(sg)?","accepted_values":["Did we know you (sg)?","Did we know you (singular)?"],"reasoning":"nirum is 'we', nɤ is second-person singular, and cʰam is 'know'. The subject outranks the object, so past t-...-ʔ combines with first-person-plural -i."},
|
| 49 |
+
{"subpart":"a","id":"a.6","target":"Translate item 6, 'nirum ka tiʔ ne', into English.","answer":"Did we go?","reasoning":"nirum is 'we' and ka is 'go'. The past complex t-i-ʔ marks first-person plural."},
|
| 50 |
+
{"subpart":"b","id":"b.1","target":"Translate item 7, 'Did I beat you(sg)?', into Hakhun.","answer":"ŋabə nɤ lan tɤʔ ne","reasoning":"Use ŋa-bə as a first-person-singular transitive subject, nɤ as the object, lan 'beat', and past t-...-ʔ with first-person-singular -ɤ."},
|
| 51 |
+
{"subpart":"b","id":"b.2","target":"Translate item 8, 'Did they see me?', into Hakhun.","answer":"tarum kəmə ŋa lapkʰi tʰɤ ne","reasoning":"Use tarum kəmə for the plural third-person subject and ŋa for the first-person-singular object. The object outranks the subject, so past tʰ- takes -ɤ."},
|
| 52 |
+
{"subpart":"b","id":"b.3","target":"Translate item 9, 'Does he know you(sg)?', into Hakhun.","answer":"ati kəmə nɤ cʰam ru ne","reasoning":"Use ati kəmə for the third-person subject, nɤ for the higher-ranked second-person-singular object, cʰam 'know', and present r- plus -u."},
|
| 53 |
+
{"subpart":"b","id":"b.4","target":"Translate item 10, 'Do you(pl) sleep?', into Hakhun.","answer":"nuʔrum ʒip kan ne","reasoning":"Use nuʔrum for second-person plural and ʒip 'sleep'. Present k- takes the second-person-plural suffix -an."}
|
| 54 |
+
]
|
| 55 |
+
},
|
| 56 |
+
{
|
| 57 |
+
"source_problem_id": "2018-individual-3",
|
| 58 |
+
"year": 2018,
|
| 59 |
+
"title": "Terêna",
|
| 60 |
+
"problem_pdf_page_1_indexed": 3,
|
| 61 |
+
"solution_pdf_page_1_indexed": 2,
|
| 62 |
+
"problem_body": "Problem 3 (20 points). Here are some words in Terêna in two grammatical forms: first-person singular ('my ...' or 'I ...') and second-person singular ('your ...' or 'you ...'). Some forms are missing.\n\nfirst person | second person | meaning\nîmam | îme | husband\nmbîho | [gap 1] | to go\nyónom | yéno | to walk\nmbôro | peôro | pants\nndûti | tiûti | head\nâyom | yâyo | brother of a woman\n[gap 2] | pîyo | animal\nyênom | [gap 3] | wife\nmbûyu | piûyu | knee\nnjûpa | xiûpa | manioc\n[gap 4] | yêno | mother\nnênem | nîni | tongue\nmbâho | peâho | mouth\nndâki | teâki | arm\nvô’um | veô’u | hand\nngásaxo | [gap 5] | to feel cold\nnjérere | [gap 6] | side\nmônzi | meôhi | toy\nndôko | [gap 7] | nape\nímbovo | ípevo | clothes\nenjóvi | yexóvi | elder sibling\nnoínjoa | [gap 8] | to see it\nvanénjo | [gap 9] | to buy\nmbepékena | pipíkina | drum\nongóvo | yokóvo | stomach, soul\nrembéno | ripíno | shirt\nnje’éxa | xi’íxa | son/daughter\nivándako | ivétako | to sit\nmbirítauna | piríteuna | knife\nmómindi | [gap 10] | to be tired\nnjovó’i | xevó’i | hat\nngónokoa | kénokoa | to need it\nínzikaxovoku | [gap 11] | school\n[gap 12] | yôxu | grandfather\níningone | ínikene | friend\nvandékena | vetékena | canoe\nóvongu | yóvoku | house\n[gap 13] | nîwo | nephew\nánzarana | [gap 14] | hoe\nnzapátuna | hepátuna | shoe\n\n(a) Fill in gaps 1-14.\n\n(b) Portuguese loanwords sometimes behave unusually. Compare lámbina/leápina 'pencil', leátana 'tin can', and keápana 'cloak'.\n1. How do these loanwords differ from native Terêna words?\n2. Translate into Terêna: my tin can; my cloak.\n\n’ is a consonant. x = sh in sheesh. y = y in yum. nj = n plus si in vision. Word-final m nasalizes the whole word. A circumflex lengthens the vowel with falling pitch; an acute mark lengthens the following consonant.",
|
| 63 |
+
"checked_rules": [
|
| 64 |
+
"For first-person singular, if a word has a voiceless consonant, the first such consonant becomes nasal plus voiced: p→mb, t→nd, h→nz, x→nj, k→ng. Otherwise the whole word is nasalized with final -m.",
|
| 65 |
+
"For second-person singular, a word beginning in a vowel other than i, í, or î takes y-. Otherwise the first vowel other than i, í, or î changes: a→e, á→é, â→eâ; o→e, ó→é, ô→eô; û→iû; e→i, é→í, ê→î, including immediately following syllables.",
|
| 66 |
+
"In Portuguese loans the second-person-singular change is á→eá, unlike native á→é and â→eâ.",
|
| 67 |
+
"The official missing forms preserve all accents and glottal marks shown in the source table."
|
| 68 |
+
],
|
| 69 |
+
"tasks": [
|
| 70 |
+
{"subpart":"a","id":"a.1","target":"Fill gap 1: give the second-person-singular form of mbîho 'to go'.","answer":"pîhe","reasoning":"Reverse first-person nasal voicing mb→p to recover pîho, then apply second-person o→e, giving pîhe."},
|
| 71 |
+
{"subpart":"a","id":"a.2","target":"Fill gap 2: give the first-person-singular form corresponding to pîyo 'animal'.","answer":"mbêyo","reasoning":"First-person singular changes the first voiceless consonant p to mb; the underlying first vowel is ê, yielding mbêyo."},
|
| 72 |
+
{"subpart":"a","id":"a.3","target":"Fill gap 3: give the second-person-singular form of yênom 'wife'.","answer":"yîno","reasoning":"Change the first non-i vowel ê to î and remove the first-person nasalizing final m; the following o is unchanged, yielding yîno."},
|
| 73 |
+
{"subpart":"a","id":"a.4","target":"Fill gap 4: give the first-person-singular form corresponding to yêno 'mother'.","answer":"ênom","reasoning":"The second-person y- was added before an initial non-i vowel. Removing y- recovers êno, and first person nasalizes the voiceless-consonant-free word with final m: ênom."},
|
| 74 |
+
{"subpart":"a","id":"a.5","target":"Fill gap 5: give the second-person-singular form of ngásaxo 'to feel cold'.","answer":"késaxo","reasoning":"Reverse first-person ng→k, then apply the native second-person change á→é, yielding késaxo."},
|
| 75 |
+
{"subpart":"a","id":"a.6","target":"Fill gap 6: give the second-person-singular form of njérere 'side'.","answer":"xíriri","reasoning":"Reverse first-person nj→x. Second person changes é→í and the immediately following e vowels to i, yielding xíriri."},
|
| 76 |
+
{"subpart":"a","id":"a.7","target":"Fill gap 7: give the second-person-singular form of ndôko 'nape'.","answer":"teôko","reasoning":"Reverse first-person nd→t and apply second-person ô→eô, giving teôko."},
|
| 77 |
+
{"subpart":"a","id":"a.8","target":"Fill gap 8: give the second-person-singular form of noínjoa 'to see it'.","answer":"neíxoa","reasoning":"The first eligible vowel o changes to e; the corresponding oral consonant is x rather than first-person nj, giving neíxoa."},
|
| 78 |
+
{"subpart":"a","id":"a.9","target":"Fill gap 9: give the second-person-singular form of vanénjo 'to buy'.","answer":"venéxo","reasoning":"Change the first eligible vowel a to e and reverse first-person nj to x, yielding venéxo."},
|
| 79 |
+
{"subpart":"a","id":"a.10","target":"Fill gap 10: give the second-person-singular form of mómindi 'to be tired'.","answer":"mémiti","reasoning":"Apply second-person ó→é and use the oral t corresponding to first-person nd; the i vowels remain unchanged, yielding mémiti."},
|
| 80 |
+
{"subpart":"a","id":"a.11","target":"Fill gap 11: give the second-person-singular form of ínzikaxovoku 'school'.","answer":"íhikexovoku","reasoning":"The first-person nz corresponds to h. The first eligible vowel a changes to e, yielding íhikexovoku."},
|
| 81 |
+
{"subpart":"a","id":"a.12","target":"Fill gap 12: give the first-person-singular form corresponding to yôxu 'grandfather'.","answer":"ônju","reasoning":"Remove second-person y- to recover initial ô, then change the first voiceless consonant x to nj for first person: ônju."},
|
| 82 |
+
{"subpart":"a","id":"a.13","target":"Fill gap 13: give the first-person-singular form corresponding to nîwo 'nephew'.","answer":"nêwom","reasoning":"The second-person vowel î corresponds to underlying ê. With no voiceless consonant, first person nasalizes the whole word with final m, yielding nêwom."},
|
| 83 |
+
{"subpart":"a","id":"a.14","target":"Fill gap 14: give the second-person-singular form of ánzarana 'hoe'.","answer":"yáharana","reasoning":"Because the underlying word begins with á, second person adds y-. Reverse first-person nz to h, yielding yáharana."},
|
| 84 |
+
{"subpart":"b","id":"b.1","target":"State the second-person-singular vowel rule that distinguishes the Portuguese loanwords from native Terêna words. Use arrow notation.","answer":"Portuguese á→eá versus native á→é and â→eâ","accepted_values":["Portuguese á → eá versus native á → é and â → eâ","In Portuguese loanwords á becomes eá whereas in native words á becomes é and â becomes eâ."],"reasoning":"leápina, leátana, and keápana show loanword á→eá. Native pairs such as ngásaxo/késaxo and mbâho/peâho instead show á→é and â→eâ."},
|
| 85 |
+
{"subpart":"b","id":"b.2.1","target":"Translate 'my tin can' into Terêna.","answer":"lándana","reasoning":"The loan base is látana. First person changes its first voiceless consonant t to nasal-plus-voiced nd, yielding lándana."},
|
| 86 |
+
{"subpart":"b","id":"b.2.2","target":"Translate 'my cloak' into Terêna.","answer":"ngápana","reasoning":"Reverse second-person keápana to the loan base kápana, then apply first-person k→ng to obtain ngápana."}
|
| 87 |
+
]
|
| 88 |
+
}
|
| 89 |
+
]
|
| 90 |
+
}
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherContextSettings.cs
ADDED
|
@@ -0,0 +1,113 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
using System;
|
| 2 |
+
using System.IO;
|
| 3 |
+
using UnityEditor.TestTools.TestRunner.Api;
|
| 4 |
+
using UnityEngine;
|
| 5 |
+
|
| 6 |
+
namespace UnityEditor.TestTools.TestRunner
|
| 7 |
+
{
|
| 8 |
+
internal class PlayerLauncherContextSettings : IDisposable
|
| 9 |
+
{
|
| 10 |
+
private ITestRunSettings m_OverloadSettings;
|
| 11 |
+
|
| 12 |
+
private EditorBuildSettingsScene[] m_EditorBuildSettings;
|
| 13 |
+
#pragma warning disable 618
|
| 14 |
+
private ResolutionDialogSetting m_DisplayResolutionDialog;
|
| 15 |
+
#pragma warning restore 618
|
| 16 |
+
private bool m_RunInBackground;
|
| 17 |
+
private FullScreenMode m_FullScreenMode;
|
| 18 |
+
private bool m_ResizableWindow;
|
| 19 |
+
private bool m_ShowUnitySplashScreen;
|
| 20 |
+
private string m_OldproductName;
|
| 21 |
+
private string m_OldAotOptions;
|
| 22 |
+
#pragma warning disable 618
|
| 23 |
+
private Lightmapping.GIWorkflowMode m_OldLightmapping;
|
| 24 |
+
#pragma warning restore 618
|
| 25 |
+
private bool m_explicitNullChecks;
|
| 26 |
+
|
| 27 |
+
private bool m_Disposed;
|
| 28 |
+
|
| 29 |
+
public PlayerLauncherContextSettings(ITestRunSettings overloadSettings)
|
| 30 |
+
{
|
| 31 |
+
m_OverloadSettings = overloadSettings;
|
| 32 |
+
SetupProjectParameters();
|
| 33 |
+
|
| 34 |
+
if (overloadSettings != null)
|
| 35 |
+
{
|
| 36 |
+
overloadSettings.Apply();
|
| 37 |
+
}
|
| 38 |
+
}
|
| 39 |
+
|
| 40 |
+
public void Dispose()
|
| 41 |
+
{
|
| 42 |
+
if (!m_Disposed)
|
| 43 |
+
{
|
| 44 |
+
CleanupProjectParameters();
|
| 45 |
+
if (m_OverloadSettings != null)
|
| 46 |
+
{
|
| 47 |
+
m_OverloadSettings.Dispose();
|
| 48 |
+
}
|
| 49 |
+
|
| 50 |
+
m_Disposed = true;
|
| 51 |
+
}
|
| 52 |
+
}
|
| 53 |
+
|
| 54 |
+
private void SetupProjectParameters()
|
| 55 |
+
{
|
| 56 |
+
EditorApplication.LockReloadAssemblies();
|
| 57 |
+
|
| 58 |
+
m_EditorBuildSettings = EditorBuildSettings.scenes;
|
| 59 |
+
|
| 60 |
+
#pragma warning disable 618
|
| 61 |
+
m_DisplayResolutionDialog = PlayerSettings.displayResolutionDialog;
|
| 62 |
+
PlayerSettings.displayResolutionDialog = ResolutionDialogSetting.Disabled;
|
| 63 |
+
#pragma warning restore 618
|
| 64 |
+
|
| 65 |
+
m_RunInBackground = PlayerSettings.runInBackground;
|
| 66 |
+
PlayerSettings.runInBackground = true;
|
| 67 |
+
|
| 68 |
+
m_FullScreenMode = PlayerSettings.fullScreenMode;
|
| 69 |
+
PlayerSettings.fullScreenMode = FullScreenMode.Windowed;
|
| 70 |
+
|
| 71 |
+
m_OldAotOptions = PlayerSettings.aotOptions;
|
| 72 |
+
PlayerSettings.aotOptions = "nimt-trampolines=1024";
|
| 73 |
+
|
| 74 |
+
m_ResizableWindow = PlayerSettings.resizableWindow;
|
| 75 |
+
PlayerSettings.resizableWindow = true;
|
| 76 |
+
|
| 77 |
+
m_ShowUnitySplashScreen = PlayerSettings.SplashScreen.show;
|
| 78 |
+
PlayerSettings.SplashScreen.show = false;
|
| 79 |
+
|
| 80 |
+
m_OldproductName = PlayerSettings.productName;
|
| 81 |
+
PlayerSettings.productName = string.Join("_", Application.productName.Split(Path.GetInvalidFileNameChars()));
|
| 82 |
+
|
| 83 |
+
#pragma warning disable 618
|
| 84 |
+
m_OldLightmapping = Lightmapping.giWorkflowMode;
|
| 85 |
+
Lightmapping.giWorkflowMode = Lightmapping.GIWorkflowMode.OnDemand;
|
| 86 |
+
#pragma warning restore 618
|
| 87 |
+
|
| 88 |
+
m_explicitNullChecks = EditorUserBuildSettings.explicitNullChecks;
|
| 89 |
+
EditorUserBuildSettings.explicitNullChecks = true;
|
| 90 |
+
}
|
| 91 |
+
|
| 92 |
+
private void CleanupProjectParameters()
|
| 93 |
+
{
|
| 94 |
+
EditorBuildSettings.scenes = m_EditorBuildSettings;
|
| 95 |
+
|
| 96 |
+
PlayerSettings.fullScreenMode = m_FullScreenMode;
|
| 97 |
+
PlayerSettings.runInBackground = m_RunInBackground;
|
| 98 |
+
#pragma warning disable 618
|
| 99 |
+
PlayerSettings.displayResolutionDialog = m_DisplayResolutionDialog;
|
| 100 |
+
#pragma warning restore 618
|
| 101 |
+
PlayerSettings.resizableWindow = m_ResizableWindow;
|
| 102 |
+
PlayerSettings.SplashScreen.show = m_ShowUnitySplashScreen;
|
| 103 |
+
PlayerSettings.productName = m_OldproductName;
|
| 104 |
+
PlayerSettings.aotOptions = m_OldAotOptions;
|
| 105 |
+
#pragma warning disable 618
|
| 106 |
+
Lightmapping.giWorkflowMode = m_OldLightmapping;
|
| 107 |
+
#pragma warning restore 618
|
| 108 |
+
EditorUserBuildSettings.explicitNullChecks = m_explicitNullChecks;
|
| 109 |
+
|
| 110 |
+
EditorApplication.UnlockReloadAssemblies();
|
| 111 |
+
}
|
| 112 |
+
}
|
| 113 |
+
}
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherContextSettings.cs.meta
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
fileFormatVersion: 2
|
| 2 |
+
guid: 6965880f76f40194593cb53a88f74005
|
| 3 |
+
MonoImporter:
|
| 4 |
+
externalObjects: {}
|
| 5 |
+
serializedVersion: 2
|
| 6 |
+
defaultReferences: []
|
| 7 |
+
executionOrder: 0
|
| 8 |
+
icon: {instanceID: 0}
|
| 9 |
+
userData:
|
| 10 |
+
assetBundleName:
|
| 11 |
+
assetBundleVariant:
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherTestRunSettings.cs
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
using UnityEditor.TestTools.TestRunner.Api;
|
| 2 |
+
|
| 3 |
+
namespace UnityEditor.TestTools.TestRunner
|
| 4 |
+
{
|
| 5 |
+
class PlayerLauncherTestRunSettings : ITestRunSettings
|
| 6 |
+
{
|
| 7 |
+
public bool buildOnly { set; get; }
|
| 8 |
+
|
| 9 |
+
public string buildOnlyLocationPath { set; get; }
|
| 10 |
+
|
| 11 |
+
public void Dispose()
|
| 12 |
+
{
|
| 13 |
+
}
|
| 14 |
+
|
| 15 |
+
void ITestRunSettings.Apply()
|
| 16 |
+
{
|
| 17 |
+
}
|
| 18 |
+
}
|
| 19 |
+
}
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlayerLauncherTestRunSettings.cs.meta
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
fileFormatVersion: 2
|
| 2 |
+
guid: c1cba6f3ed484514097080a3bb835958
|
| 3 |
+
MonoImporter:
|
| 4 |
+
externalObjects: {}
|
| 5 |
+
serializedVersion: 2
|
| 6 |
+
defaultReferences: []
|
| 7 |
+
executionOrder: 0
|
| 8 |
+
icon: {instanceID: 0}
|
| 9 |
+
userData:
|
| 10 |
+
assetBundleName:
|
| 11 |
+
assetBundleVariant:
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlaymodeLauncher.cs
ADDED
|
@@ -0,0 +1,133 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
using System;
|
| 2 |
+
using System.Collections.Generic;
|
| 3 |
+
using System.Linq;
|
| 4 |
+
using NUnit.Framework.Interfaces;
|
| 5 |
+
using NUnit.Framework.Internal.Filters;
|
| 6 |
+
using UnityEditor.TestTools.TestRunner.Api;
|
| 7 |
+
using UnityEngine;
|
| 8 |
+
using UnityEngine.SceneManagement;
|
| 9 |
+
using UnityEngine.TestRunner.Utils;
|
| 10 |
+
using UnityEngine.TestTools.TestRunner;
|
| 11 |
+
using UnityEngine.TestTools.TestRunner.Callbacks;
|
| 12 |
+
|
| 13 |
+
namespace UnityEditor.TestTools.TestRunner
|
| 14 |
+
{
|
| 15 |
+
internal class PlaymodeLauncher : RuntimeTestLauncherBase
|
| 16 |
+
{
|
| 17 |
+
public static bool IsRunning;
|
| 18 |
+
private Scene m_Scene;
|
| 19 |
+
private bool m_IsTestSetupPerformed;
|
| 20 |
+
private readonly PlaymodeTestsControllerSettings m_Settings;
|
| 21 |
+
private ITestFilter testFilter;
|
| 22 |
+
|
| 23 |
+
[SerializeField]
|
| 24 |
+
private List<Type> m_EventHandlers = new List<Type>();
|
| 25 |
+
|
| 26 |
+
public PlaymodeLauncher(PlaymodeTestsControllerSettings settings)
|
| 27 |
+
{
|
| 28 |
+
m_Settings = settings;
|
| 29 |
+
}
|
| 30 |
+
|
| 31 |
+
public override void Run()
|
| 32 |
+
{
|
| 33 |
+
IsRunning = true;
|
| 34 |
+
ConsoleWindow.SetConsoleErrorPause(false);
|
| 35 |
+
Application.runInBackground = true;
|
| 36 |
+
|
| 37 |
+
var sceneName = CreateSceneName();
|
| 38 |
+
m_Scene = CreateBootstrapScene(sceneName, runner =>
|
| 39 |
+
{
|
| 40 |
+
runner.AddEventHandlerMonoBehaviour<PlayModeRunnerCallback>();
|
| 41 |
+
runner.AddEventHandlerScriptableObject<TestRunnerCallback>();
|
| 42 |
+
runner.AddEventHandlerScriptableObject<CallbacksDelegatorListener>();
|
| 43 |
+
runner.AddEventHandlerScriptableObject<TestRunCallbackListener>();
|
| 44 |
+
|
| 45 |
+
foreach (var eventHandler in m_EventHandlers)
|
| 46 |
+
{
|
| 47 |
+
var obj = ScriptableObject.CreateInstance(eventHandler);
|
| 48 |
+
runner.AddEventHandlerScriptableObject(obj as ITestRunnerListener);
|
| 49 |
+
}
|
| 50 |
+
|
| 51 |
+
runner.settings = m_Settings;
|
| 52 |
+
});
|
| 53 |
+
|
| 54 |
+
if (m_Settings.sceneBased)
|
| 55 |
+
{
|
| 56 |
+
var newListOfScenes =
|
| 57 |
+
new List<EditorBuildSettingsScene> {new EditorBuildSettingsScene(sceneName, true)};
|
| 58 |
+
newListOfScenes.AddRange(EditorBuildSettings.scenes);
|
| 59 |
+
EditorBuildSettings.scenes = newListOfScenes.ToArray();
|
| 60 |
+
}
|
| 61 |
+
|
| 62 |
+
EditorApplication.update += UpdateCallback;
|
| 63 |
+
}
|
| 64 |
+
|
| 65 |
+
public void UpdateCallback()
|
| 66 |
+
{
|
| 67 |
+
if (m_IsTestSetupPerformed)
|
| 68 |
+
{
|
| 69 |
+
if (m_Scene.IsValid())
|
| 70 |
+
SceneManager.SetActiveScene(m_Scene);
|
| 71 |
+
EditorApplication.update -= UpdateCallback;
|
| 72 |
+
EditorApplication.isPlaying = true;
|
| 73 |
+
}
|
| 74 |
+
else
|
| 75 |
+
{
|
| 76 |
+
testFilter = m_Settings.BuildNUnitFilter();
|
| 77 |
+
var runner = LoadTests(testFilter);
|
| 78 |
+
|
| 79 |
+
var exceptionThrown = ExecutePreBuildSetupMethods(runner.LoadedTest, testFilter);
|
| 80 |
+
if (exceptionThrown)
|
| 81 |
+
{
|
| 82 |
+
EditorApplication.update -= UpdateCallback;
|
| 83 |
+
IsRunning = false;
|
| 84 |
+
var controller = PlaymodeTestsController.GetController();
|
| 85 |
+
ReopenOriginalScene(controller);
|
| 86 |
+
AssetDatabase.DeleteAsset(controller.settings.bootstrapScene);
|
| 87 |
+
CallbacksDelegator.instance.RunFailed("Run Failed: One or more errors in a prebuild setup. See the editor log for details.");
|
| 88 |
+
return;
|
| 89 |
+
}
|
| 90 |
+
m_IsTestSetupPerformed = true;
|
| 91 |
+
}
|
| 92 |
+
}
|
| 93 |
+
|
| 94 |
+
[InitializeOnLoad]
|
| 95 |
+
public class BackgroundWatcher
|
| 96 |
+
{
|
| 97 |
+
static BackgroundWatcher()
|
| 98 |
+
{
|
| 99 |
+
EditorApplication.playModeStateChanged += OnPlayModeStateChanged;
|
| 100 |
+
}
|
| 101 |
+
|
| 102 |
+
private static void OnPlayModeStateChanged(PlayModeStateChange state)
|
| 103 |
+
{
|
| 104 |
+
if (!PlaymodeTestsController.IsControllerOnScene())
|
| 105 |
+
return;
|
| 106 |
+
var runner = PlaymodeTestsController.GetController();
|
| 107 |
+
if (runner == null)
|
| 108 |
+
return;
|
| 109 |
+
if (state == PlayModeStateChange.ExitingPlayMode)
|
| 110 |
+
{
|
| 111 |
+
AssetDatabase.DeleteAsset(runner.settings.bootstrapScene);
|
| 112 |
+
ExecutePostBuildCleanupMethods(runner.m_Runner.LoadedTest, runner.settings.BuildNUnitFilter(), Application.platform);
|
| 113 |
+
IsRunning = false;
|
| 114 |
+
}
|
| 115 |
+
else if (state == PlayModeStateChange.EnteredEditMode)
|
| 116 |
+
{
|
| 117 |
+
//reopen the original scene once we exit playmode
|
| 118 |
+
ReopenOriginalScene(runner);
|
| 119 |
+
}
|
| 120 |
+
}
|
| 121 |
+
}
|
| 122 |
+
|
| 123 |
+
protected static void ReopenOriginalScene(PlaymodeTestsController runner)
|
| 124 |
+
{
|
| 125 |
+
ReopenOriginalScene(runner.settings.originalScene);
|
| 126 |
+
}
|
| 127 |
+
|
| 128 |
+
public void AddEventHandler<T>() where T : ScriptableObject, ITestRunnerListener
|
| 129 |
+
{
|
| 130 |
+
m_EventHandlers.Add(typeof(T));
|
| 131 |
+
}
|
| 132 |
+
}
|
| 133 |
+
}
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PlaymodeLauncher.cs.meta
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
fileFormatVersion: 2
|
| 2 |
+
guid: d3217d58bbd1d2b4aaee933e2e8b9195
|
| 3 |
+
MonoImporter:
|
| 4 |
+
externalObjects: {}
|
| 5 |
+
serializedVersion: 2
|
| 6 |
+
defaultReferences: []
|
| 7 |
+
executionOrder: 0
|
| 8 |
+
icon: {instanceID: 0}
|
| 9 |
+
userData:
|
| 10 |
+
assetBundleName:
|
| 11 |
+
assetBundleVariant:
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PostbuildCleanupAttributeFinder.cs
ADDED
|
@@ -0,0 +1,9 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
using UnityEngine.TestTools;
|
| 2 |
+
|
| 3 |
+
namespace UnityEditor.TestTools.TestRunner
|
| 4 |
+
{
|
| 5 |
+
internal class PostbuildCleanupAttributeFinder : AttributeFinderBase<IPostBuildCleanup, PostBuildCleanupAttribute>
|
| 6 |
+
{
|
| 7 |
+
public PostbuildCleanupAttributeFinder() : base(attribute => attribute.TargetClass) {}
|
| 8 |
+
}
|
| 9 |
+
}
|
benchmark/NYU_CTF_Bench/test/2022/CSAW-Quals/rev/AnyaGacha/src/client/Library/PackageCache/com.unity.test-framework@1.1.22/UnityEditor.TestRunner/TestLaunchers/PostbuildCleanupAttributeFinder.cs.meta
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
fileFormatVersion: 2
|
| 2 |
+
guid: 2c2dfcbbb77359547bcaa7cdabd47ebb
|
| 3 |
+
MonoImporter:
|
| 4 |
+
externalObjects: {}
|
| 5 |
+
serializedVersion: 2
|
| 6 |
+
defaultReferences: []
|
| 7 |
+
executionOrder: 0
|
| 8 |
+
icon: {instanceID: 0}
|
| 9 |
+
userData:
|
| 10 |
+
assetBundleName:
|
| 11 |
+
assetBundleVariant:
|