# Explainable AI-Enhanced Human Activity Recognition for Human-Robot Collaboration in Agriculture
## 2 Materials and Methods
### Data Acquisition
Bending to approach an empty crate (Class 2): this activity is marked by the participant initiating trunk flexion, knee flexion, or a combination of both;
4. Bending to approach a full crate (Class 3): this activity follows the same criteria as activity 3, but involves a full crate instead of an empty one;
5. Lifting an empty crate (Class 4): this activity involves transitioning from a bent posture to an upright standing position while lifting the crate;
6. Lifting a full crate (Class 5): The criteria for this activity are identical to those of activity 5, but with a full crate instead of an empty one;
7. Walking with an empty crate (Class 6): the stance phase of gait marks the onset of this activity, similarly to activity 2, but while carrying an empty crate;
8. Walking with a full crate (Class 7): this activity is similar to activity 7 but performed while carrying a full crate;
9. Placing an empty crate onto the UGV (Class 8): task initiation is marked by the onset of trunk or knee flexion by the participant to initiate the lowering of the crate, and the task terminates upon the successful deposition of the empty crate on the robotic system;
10. Placing a full crate onto the UGV (Class 9): this activity follows the same criteria as activity 9 but involves a full crate instead of an empty one. As compared to the ML algorithm used in [26; 27], the algorithm developed in this study not only recognizes distinct activities but also differentiates between handling an empty or full crate, thereby introducing four additional classes to the ML model. Recognizing heavier loads allows robots to provide timely assistance, reducing ergonomic stress on human workers [8]. Moreover, distinguishing crate types facilitates more efficient load management, enabling robots to optimize their movements and conserve energy. In dynamic agricultural workflows, identifying the weight of a crate could also help robots anticipate human intentions, improving coordination and promoting smoother interactions. Importantly, since empty and full crates correspond to different stages of the harvesting process, this differentiation aids in task prioritization and workflow optimization, ultimately making the system more robust and better suited to the practical demands of real-world agricultural environments [6]. To optimize data acquisition with a limited sensor array, the sensor placement strategy prioritized the upper-body and core regions to capture the activities under investigation. As detailed in [27], the sensor positioned over the sternum yields critical insights into whole-body movements and postural adjustments. The neck sensor, near the T1 vertebra, captures upper-body movements and alignment, which are important for actions such as bending and lifting. The lumbar region sensor, positioned near the L4 vertebra, helps monitor lower-back motion, which is crucial for material handling activities. Finally, the wrist sensors track detailed hand and arm movements, which are essential for tasks that require the precise handling and coordination of the crate. Wrist sensors were fastened in place using Velcro straps, as shown in Figure 1, while double-sided tape was used for the remaining sensors.