Skip to content

Commit 9fd31fc

Browse files
authored
make 1.3.0 release (#402)
* bumped version --> 1.3 * ran notebook * adds change to SI-graph plot and network plot to CHANGELOG.md * ran notebooks with version 1.3
1 parent 0622bd7 commit 9fd31fc

21 files changed

+1576
-1611
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
- made `InteractionValues.get_n_order()` and `InteractionValues.get_n_order_values()` function more efficient by iterating over the stored interactions and not over the powerset of all potential interactions, which made the function not usable for higher player counts (models with many features, and results obtained from `TreeExplainer`). Note, this change does not really help `get_n_order_values()` as it still needs to create a numpy array of shape `n_players` times `order` [#372](https://github.com/mmschlk/shapiq/pull/372)
1212
- streamlined the ``network_plot()`` plot function to use the ``si_graph_plot()`` as its backend function. This allows for more flexibility in the plot function and makes it easier to use the same code for different purposes. In addition, the ``si_graph_plot`` was modified to make plotting more easy and allow for more flexibility with new parameters. [#349](https://github.com/mmschlk/shapiq/pull/349)
1313
- adds `Game.compute()` method to the `shapiq.Game` class to compute game values without changing the state of the game object. The compute method also introduces a `shapiq.utils.sets.generate_interaction_lookup_from_coalitions()` utility method which creates an interaction lookup dict from an array of coalitions. [#397](https://github.com/mmschlk/shapiq/pull/397)
14+
- streamlines the creation of network plots and graph plots which now uses the same backend. The network plot via `shapiq.network_plot()` or `InteractionValues.plot_network()` is now a special case of the `shapiq.si_graph_plot()` and `InteractionValues.plot_si_graph()`. This allows to create more beautiful plots and easier maintenance in the future. [#349](https://github.com/mmschlk/shapiq/pull/349)
1415

1516
#### Testing, Code-Quality and Documentation
1617
- activates ``"ALL"`` rules in ``ruff-format`` configuration to enforce stricter code quality checks and addressed around 500 (not automatically solvable) issues in the code base. [#391](https://github.com/mmschlk/shapiq/pull/391)

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@
1111
[![PePy](https://static.pepy.tech/badge/shapiq?style=flat-square)](https://pepy.tech/project/shapiq)
1212

1313
[![Code Style](https://img.shields.io/badge/code%20style-black-000000.svg)](https://github.com/psf/black)
14-
![Contributions Welcome](https://img.shields.io/badge/contributions-welcome-brightgreen)
15-
![Last Commit](https://img.shields.io/github/last-commit/mmschlk/shapiq)
14+
[![Contributions Welcome](https://img.shields.io/badge/contributions-welcome-brightgreen)](https://github.com/mmschlk/shapiq/issues)
15+
[![Last Commit](https://img.shields.io/github/last-commit/mmschlk/shapiq)](https://github.com/mmschlk/shapiq/commits/main)
1616

1717
> An interaction may speak more than a thousand main effects.
1818
@@ -192,7 +192,7 @@ There is a lot of great resources available to get you started with Shapley valu
192192
If you use ``shapiq`` and enjoy it, please consider citing our [NeurIPS paper](https://arxiv.org/abs/2410.01649) or consider starring this repository.
193193

194194
```bibtex
195-
@inproceedings{muschalik2024shapiq,
195+
@inproceedings{Muschalik.2024b,
196196
title = {shapiq: Shapley Interactions for Machine Learning},
197197
author = {Maximilian Muschalik and Hubert Baniecki and Fabian Fumagalli and
198198
Patrick Kolpaczki and Barbara Hammer and Eyke H\"{u}llermeier},

docs/source/notebooks/basics_notebooks/custom_games.ipynb

Lines changed: 38 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,8 @@
1313
"cell_type": "code",
1414
"metadata": {
1515
"ExecuteTime": {
16-
"end_time": "2025-05-27T07:25:57.348534Z",
17-
"start_time": "2025-05-27T07:25:56.297765Z"
16+
"end_time": "2025-06-16T15:20:32.064524Z",
17+
"start_time": "2025-06-16T15:20:32.062415Z"
1818
}
1919
},
2020
"source": [
@@ -24,21 +24,18 @@
2424
"\n",
2525
"import shapiq\n",
2626
"\n",
27-
"shapiq.__version__"
27+
"print(f\"shapiq version: {shapiq.__version__}\")"
2828
],
2929
"outputs": [
3030
{
31-
"data": {
32-
"text/plain": [
33-
"'1.2.3.9000'"
34-
]
35-
},
36-
"execution_count": 1,
37-
"metadata": {},
38-
"output_type": "execute_result"
31+
"name": "stdout",
32+
"output_type": "stream",
33+
"text": [
34+
"shapiq version: 1.3.0\n"
35+
]
3936
}
4037
],
41-
"execution_count": 1
38+
"execution_count": 19
4239
},
4340
{
4441
"cell_type": "markdown",
@@ -90,8 +87,8 @@
9087
"cell_type": "code",
9188
"metadata": {
9289
"ExecuteTime": {
93-
"end_time": "2025-05-27T07:25:57.356682Z",
94-
"start_time": "2025-05-27T07:25:57.352446Z"
90+
"end_time": "2025-06-16T15:20:32.078835Z",
91+
"start_time": "2025-06-16T15:20:32.074535Z"
9592
}
9693
},
9794
"source": [
@@ -144,12 +141,12 @@
144141
"CookingGame(3 players, normalize=False, normalization_value=0, precomputed=False)"
145142
]
146143
},
147-
"execution_count": 2,
144+
"execution_count": 20,
148145
"metadata": {},
149146
"output_type": "execute_result"
150147
}
151148
],
152-
"execution_count": 2
149+
"execution_count": 20
153150
},
154151
{
155152
"cell_type": "markdown",
@@ -163,8 +160,8 @@
163160
"cell_type": "code",
164161
"metadata": {
165162
"ExecuteTime": {
166-
"end_time": "2025-05-27T07:25:57.413564Z",
167-
"start_time": "2025-05-27T07:25:57.410909Z"
163+
"end_time": "2025-06-16T15:20:32.085634Z",
164+
"start_time": "2025-06-16T15:20:32.083132Z"
168165
}
169166
},
170167
"source": [
@@ -179,19 +176,19 @@
179176
"array([ 0, 9, 8, 7, 15])"
180177
]
181178
},
182-
"execution_count": 3,
179+
"execution_count": 21,
183180
"metadata": {},
184181
"output_type": "execute_result"
185182
}
186183
],
187-
"execution_count": 3
184+
"execution_count": 21
188185
},
189186
{
190187
"cell_type": "code",
191188
"metadata": {
192189
"ExecuteTime": {
193-
"end_time": "2025-05-27T07:25:57.424552Z",
194-
"start_time": "2025-05-27T07:25:57.422121Z"
190+
"end_time": "2025-06-16T15:20:32.092193Z",
191+
"start_time": "2025-06-16T15:20:32.089699Z"
195192
}
196193
},
197194
"source": [
@@ -212,19 +209,19 @@
212209
"array([ 0, 9, 8, 7, 15])"
213210
]
214211
},
215-
"execution_count": 4,
212+
"execution_count": 22,
216213
"metadata": {},
217214
"output_type": "execute_result"
218215
}
219216
],
220-
"execution_count": 4
217+
"execution_count": 22
221218
},
222219
{
223220
"cell_type": "code",
224221
"metadata": {
225222
"ExecuteTime": {
226-
"end_time": "2025-05-27T07:25:57.443453Z",
227-
"start_time": "2025-05-27T07:25:57.441644Z"
223+
"end_time": "2025-06-16T15:20:32.105678Z",
224+
"start_time": "2025-06-16T15:20:32.103860Z"
228225
}
229226
},
230227
"source": [
@@ -244,7 +241,7 @@
244241
]
245242
}
246243
],
247-
"execution_count": 5
244+
"execution_count": 23
248245
},
249246
{
250247
"cell_type": "markdown",
@@ -261,8 +258,8 @@
261258
"cell_type": "code",
262259
"metadata": {
263260
"ExecuteTime": {
264-
"end_time": "2025-05-27T07:25:57.502377Z",
265-
"start_time": "2025-05-27T07:25:57.462610Z"
261+
"end_time": "2025-06-16T15:20:32.119911Z",
262+
"start_time": "2025-06-16T15:20:32.114906Z"
266263
}
267264
},
268265
"source": [
@@ -295,7 +292,7 @@
295292
"application/vnd.jupyter.widget-view+json": {
296293
"version_major": 2,
297294
"version_minor": 0,
298-
"model_id": "2f44d89de8a14713865c0cd7e3a8661c"
295+
"model_id": "05bf32c208f04d74859ef98492bb9957"
299296
}
300297
},
301298
"metadata": {},
@@ -310,7 +307,7 @@
310307
]
311308
}
312309
],
313-
"execution_count": 6
310+
"execution_count": 24
314311
},
315312
{
316313
"cell_type": "markdown",
@@ -324,8 +321,8 @@
324321
"cell_type": "code",
325322
"metadata": {
326323
"ExecuteTime": {
327-
"end_time": "2025-05-27T07:25:57.573362Z",
328-
"start_time": "2025-05-27T07:25:57.568146Z"
324+
"end_time": "2025-06-16T15:20:32.128002Z",
325+
"start_time": "2025-06-16T15:20:32.124391Z"
329326
}
330327
},
331328
"source": [
@@ -349,7 +346,7 @@
349346
]
350347
}
351348
],
352-
"execution_count": 7
349+
"execution_count": 25
353350
},
354351
{
355352
"cell_type": "markdown",
@@ -363,8 +360,8 @@
363360
"cell_type": "code",
364361
"metadata": {
365362
"ExecuteTime": {
366-
"end_time": "2025-05-27T07:25:57.599153Z",
367-
"start_time": "2025-05-27T07:25:57.595724Z"
363+
"end_time": "2025-06-16T15:20:32.140328Z",
364+
"start_time": "2025-06-16T15:20:32.137239Z"
368365
}
369366
},
370367
"source": [
@@ -390,12 +387,12 @@
390387
"array([ 0., 9., 8., 7., 15.])"
391388
]
392389
},
393-
"execution_count": 8,
390+
"execution_count": 26,
394391
"metadata": {},
395392
"output_type": "execute_result"
396393
}
397394
],
398-
"execution_count": 8
395+
"execution_count": 26
399396
},
400397
{
401398
"cell_type": "markdown",
@@ -409,8 +406,8 @@
409406
"cell_type": "code",
410407
"metadata": {
411408
"ExecuteTime": {
412-
"end_time": "2025-05-27T07:25:57.611952Z",
413-
"start_time": "2025-05-27T07:25:57.610028Z"
409+
"end_time": "2025-06-16T15:20:32.145431Z",
410+
"start_time": "2025-06-16T15:20:32.143884Z"
414411
}
415412
},
416413
"source": [
@@ -430,7 +427,7 @@
430427
]
431428
}
432429
],
433-
"execution_count": 9
430+
"execution_count": 27
434431
}
435432
],
436433
"metadata": {

docs/source/notebooks/basics_notebooks/data_valuation.ipynb

Lines changed: 38 additions & 38 deletions
Large diffs are not rendered by default.

docs/source/notebooks/basics_notebooks/parallel_computation.ipynb

Lines changed: 789 additions & 789 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)