Commit 1428f17
authored
Add _ignore_kwargs function to filter kwargs based on function signature
This new utility function filters keyword arguments to only those accepted by the specified function, logging any ignored keys. It is integrated into the model building process to ensure compatibility with model initialization.1 parent 03f4f4d commit 1428f17
1 file changed
+15
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | 2 | | |
3 | 3 | | |
| 4 | + | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
| |||
303 | 304 | | |
304 | 305 | | |
305 | 306 | | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
306 | 320 | | |
307 | 321 | | |
308 | 322 | | |
| |||
441 | 455 | | |
442 | 456 | | |
443 | 457 | | |
| 458 | + | |
444 | 459 | | |
445 | 460 | | |
446 | 461 | | |
| |||
0 commit comments