BL-23: clip_scope: global default paired with unreviewed clipping_norm: 1.0 may over-clip cache_model_0 reference weights
Los mantenedores suelen responder en 1 día
Nadie ha tomado este issue todavía.
Evaluación
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Aptitud para principiantes
- 48/100
- Tipo de issue
- Error
- Claridad
- Bastante claro
- Estado de actividad
- Activo
- Stack tecnológico
- machine-learning, python
- Área
- backend, machine-learning
Línea de trabajo
Read cid_services/client.py, cache_model_0/manifest.json, and tests/test_cache_client_dp.py, then inspect how apply_dp_mechanism and clip_state_dict handle the global clipping bound. Run the mechanism on cache_model_0's trained state_dict and measure its combined L2 norm. If the bound clips weights aggressively, retune the manifest value and add a test for post-clip norm retention; done when the real weights are verified and the test passes.
Escrito por el modelo de indexación a partir del texto del issue.
Descripción
Summary
PR #109 (fix/dp-sensitivity) correctly defaults clip_scope to global so that noise_scale = noise_multiplier * clipping_norm is calibrated against the actual L2 bound on the combined gradient norm — the sensitivity-calibration fix itself is sound. But cache_model_0/manifest.json's clipping_norm: 1.0 was never revisited after this change, and no test in PR #109 exercises the new default against cache_model_0's real trained state_dict.
Why this matters
Under the old per_layer scope, clipping_norm: 1.0 bounded each tensor independently to norm 1.0.
Under global, clipping_norm: 1.0 bounds the combined L2 norm of all tensors to 1.0:
‖[tensor_0, tensor_1, …, tensor_n]‖₂ = sqrt(Σ ‖tensor_i‖²) ≤ 1.0
For a model with multiple floating tensors this is a much tighter constraint — sqrt(Σ ‖tensor_i‖²) can easily exceed 1.0 even if no individual tensor's norm changes. The result is that clip_state_dict clips more aggressively than before, which degrades model quality proportionally to how much the combined norm exceeds the bound.
PR #109's new tests (tests/test_cache_client_dp.py) use build_small_state_dict (synthetic tensors), not cache_model_0's real trained weights, so this is unverified.
Fix
- Run
apply_dp_mechanism/clip_state_dictagainstcache_model_0's actual trainedstate_dictunder the newglobaldefault. - Measure the combined L2 norm of the real weights before clipping.
- If
1.0clips aggressively (combined norm >> 1.0), retuneclipping_normincache_model_0/manifest.jsonto a value that allows the real weights to pass through unclipped or only lightly clipped. - Add a test in
tests/test_cache_client_dp.pythat loads the realstate_dictand asserts the combined norm post-clip is within a tolerance of the pre-clip norm.
References
Developer/BACK_LOG.mdBL-23- PR #109 (
fix/dp-sensitivity) — sensitivity fix andclip_scope: globaldefault cache_model_0/manifest.json—clipping_norm: 1.0,clip_scope: globaltests/test_cache_client_dp.py—build_small_state_dict(synthetic, not real weights)cid_services/client.py—clip_state_dict/apply_dp_mechanism
- Lenguaje dominante
- Python
- Estrellas
- 4
- Forks
- 7
- Merge medio
- 3 d 4 h
- PR fusionados (30 d)
- 34
Preparar el entorno
Este proyecto no incluye contenedor de desarrollo, Dockerfile ni guía de contribución, así que la configuración corre por tu cuenta: empieza por su README y consulta nuestra guía para la primera contribución para los pasos generales.
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Más de InfiniteZeroFoundation/DevNet
-
ROADMAP.md: refresh "What is still open for P3" (several items were fixed in October)Posiblemente ocupada @umermjd11 la tomó hace 2 días. Abiertodocumentation good first issue
Dificultad 2/5 1-3 horas Aptitud para principiantes 74/100
InfiniteZeroFoundation/DevNet#285 · 1 comentario · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Update the 25 translated organisation READMEs to match the English versionPosiblemente ocupada @mrCabez la tomó hoy. Abiertogood first issue help wanted
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
InfiniteZeroFoundation/DevNet#277 · 2 comentarios · 1 asignado ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
InfiniteZeroFoundation/DevNet#266 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
InfiniteZeroFoundation/DevNet#299 · 1 comentario ·
Los mantenedores suelen responder en 1 día
-
Long run
Dificultad 5/5 Más de una semana Aptitud para principiantes 25/100
InfiniteZeroFoundation/DevNet#298 ·
Los mantenedores suelen responder en 1 día
Todos los issues de InfiniteZeroFoundation/DevNet
Issues similares
-
enhancement help wanted
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Git-Hospital/githealthcheck#61 ·
Los mantenedores suelen responder en 1 día
-
changelog investigate
Dificultad 2/5 1-3 horas Aptitud para principiantes 67/100
ramnes/notion-sdk-py#433 ·
-
Partial method descriptors raise on class accessPosiblemente ocupada @Gambit-Checkmate la tomó hoy. Abierto
Dificultad 2/5 1-3 horas Aptitud para principiantes 76/100
Los mantenedores suelen responder en 19 días
-
docs pkg:core
Dificultad 1/5 Menos de una hora Aptitud para principiantes 84/100
pydantic/pydantic-ai#11929 ·
Los mantenedores suelen responder en 1 día
-
Dificultad 2/5 1-3 horas Aptitud para principiantes 78/100
intake/intake-esm#789 ·