[Cleanup] Remove unused Polygon3 dependency (#1528)#1548
[Cleanup] Remove unused Polygon3 dependency (#1528)#1548SHAI-Akshay-Tripathi wants to merge 4 commits into
Conversation
…licts The generate_kwargs dict passed top_p, top_k, and temperature to model.generate() without setting do_sample. HuggingFace defaults do_sample to False, which silently ignores sampling parameters and falls back to greedy decoding, causing evaluation results to not reflect the configured sampling behavior. This commit derives do_sample from temperature (do_sample=True when temperature > 0) and only includes top_p, top_k, and temperature in generate_kwargs when sampling is enabled, avoiding conflicting-flag warnings in the greedy path. Users can override via kwargs. Closes open-compass#1275
Removed polygon3 dependency from requirements.
Removed 'Polygon3' from the requirements.
|
Thanks for the cleanup. Could you please double-check this dependency before removing it? |
|
You're right, thanks for catching this — my verification was flawed. I grepped for Polygon3, but the package imports as Polygon, and in spotting_eval/script.py it's loaded dynamically via importlib.import_module('Polygon') (from the evaluation_imports() dict), so there's no literal import line to find. It's then used in plg.Polygon(...) at lines 100 and 115, with no try/except fallback. |
Summary
Closes #1528.
Polygon3was listed in two requirements files but is not imported or usedanywhere in the codebase. As noted in #1528, the package bundles the GPC
component which carries proprietary licensing terms (
Other/Proprietary Licenseon PyPI), which can create friction for commercial users.Changes
Polygon3fromrequirements.txtPolygon3fromvlmeval/dataset/utils/Ocrbench_v2/requirements.txtVerification
Searched the full codebase for any usage of Polygon3 / GPC: