anon-iclr-submission/benchname-bug-localization huggingface dataset:
Repository: opendr-eu/opendr
Issue: Tests stuck on activity recognition

I think that tests now get stuck at activity recognition tests for no specific reason. I can successfully run this tests locally. However, there are three runs in which these tests seem to have stuck:

https://github.com/tasostefas/opendr_internal/pull/94/checks?check_run_id=3662854127
https://github.com/tasostefas/opendr_internal/pull/107/checks?check_run_id=3662837030
https://github.com/tasostefas/opendr_internal/pull/89/checks?check_run_id=3661815195

Changed files:
src/opendr/perception/activity_recognition/x3d/x3d_learner.py

diff --git a/src/opendr/perception/activity_recognition/x3d/x3d_learner.py b/src/opendr/perception/activity_recognition/x3d/x3d_learner.py
index e29bbc8f3..4c2602855 100644
--- a/src/opendr/perception/activity_recognition/x3d/x3d_learner.py
+++ b/src/opendr/perception/activity_recognition/x3d/x3d_learner.py
@@ -307,11 +307,10 @@ class X3DLearner(Learner):
             iters=optimizer_info["iters"],
             batch_size=optimizer_info["batch_size"],
             optimizer=optimizer_info["optimizer"],
-            # device=hparams["device"],
+            device=getattr(self, "device", "cpu"),
             threshold=inference_params["threshold"],
             backbone=inference_params["backbone"],
             network_head=inference_params["network_head"],
-            # temp_path=hparams["temp_path"],
             loss=optimizer_info["loss"],
             checkpoint_after_iter=optimizer_info["checkpoint_after_iter"],
             checkpoint_load_iter=optimizer_info["checkpoint_load_iter"],
Repository: opendr-eu/opendr
Issue: Providing Data classes with numpy arrays throws ValueError

For example in Vector, the following code snippet throws ValueError from constructor:
```python
vec = np.array([0 for _ in range(100)])
openDRVector= Vector(vec)
```
`ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()`

Numpy arrays can't be used in ctor as
` if data: ...`
We can't expect users to only provide python lists.

Fix: conditional needs to change to `if data is not None:` that i think covers all cases.

Changed files:
src/engine/data.py

diff --git a/src/engine/data.py b/src/engine/data.py
index 54a611a57..98d30da0f 100644
--- a/src/engine/data.py
+++ b/src/engine/data.py
@@ -82,7 +82,7 @@ class Vector(Data):
     def __init__(self, data=None):
         super().__init__(data)
 
-        if data:
+        if data is not None:
             self.data = data
 
     @property
@@ -148,7 +148,7 @@ class Timeseries(Data):
     def __init__(self, data=None):
         super().__init__(data)
 
-        if data:
+        if data is not None:
             self.data = data
 
     @property