Rotate blender avatar using joint angles

Hi everyone,
i’m recently using Blender for animation and I’m a newbie. I have a csv file that contains all the joint angles and I want to develop a Python script that rotates the segments of a humanoid avatar by using the angles in the csv file. Is this possible? Do you have any suggestions on how to do it?
Thank you in advance.

To rig the avatar I followed this video: Tutorial: Human Meta Rig - Blender 2.81 - YouTube

You will read values from the CSV provided they are stored as object, positions[], rotations[] and then locate each object in the scene and assign each value at the right frame.

To figure out the rest of the details, look at look at this file blender\3.1\scripts\addons\io_anim_bvh