Splitting giant action into many sub actions via python?
Got it! I was attempting to call the remove() method on a Keyframe object instead of the keyframe_points property of the FCurve. Below is working code that transforms a giant action into multiple sub-actions (working in 2.79, I'd say it should work in 2.8 as well but I don't know how extensive the changes were to the api between 2.79 and 2.8 so if you're on 2.8 your mileage may vary):
import bpy

# Define the name of the giant action containing all other sub-actions
base_action_name = &quot;bend&quot;

# Define the name, start, and end frame of each sub animation
sub_actions = [
    (&quot;sub_bend_001&quot;, 0, 14)
    ,(&quot;sub_bend_002&quot;, 15, 29)
]

for a in sub_actions:
    new_action = bpy.data.actions.get(base_action_name).copy()
    new_action.name = a[0]
    for fc in new_action.fcurves:
        # Remove unwanted frames
        for i in reversed(range(0, len(fc.keyframe_points))):
            kfp = fc.keyframe_points[i]
            frame_number = int(kfp.co[0])
            if frame_number &lt; a[1] or frame_number &gt; a[2]:
                fc.keyframe_points.remove(kfp)
        # Shift remaining frames
        offset = fc.keyframe_points[0].co[0]
        for kfp in fc.keyframe_points:
            kfp.co[0] = kfp.co[0] - offset
            kfp.handle_left[0] = kfp.handle_left[0] - offset
            kfp.handle_right[0] = kfp.handle_right[0] - offset