Can the following code be used without bpy.ops,
so i can do something like bpy.context.view_layer.objects["myobj"]
to apply scale and rotation?
bpy.ops.object.transform_apply(location=False, rotation=True, scale=True)
bpy.ops.apply.transformrotsca()