If you did not fully clear the intersection under the yellow (before the red) then technically you were in violation of the red light.
This is an incorrect statement (at least here in Washington and I suspect California too). If you enter the intersection under a yellow light, you have entered the insection under a legal movement. If you enter after the light has turned red without stopping, then you are guilty.
To carry this further, if you enter under a yellow, and are in a slow moving vehicle, such as a semi-truck, and the other direction gets a green, the other direction has to yeild to you so you can clear the intersection before they can go. If they don't and there is an accident, they are at fault, not the semi (or you).
The reason for the yellow is to provide a "delema" zone for drives to make a decision to stop and have enough distance to stop safely after they have crossed the advance vehicle detection loops (usually about 150-200 feet) prior to the stop bar. The distacne from the stop bar is based on the speed limit of the street. So if you are past the advance loops, the light turns yellow, and you cannont stop safely, it is expected by design, that you would proceed through the intersection and would have entered before the light turns red.
There is a lot of conspiracy theorist, that cities are shortening the yellow time to suuport red light cameras. The MUTCD (manual on unifrom traffic control devices) a federal publication sets the minimum yellow time of 3 seconds to a maximum of 6 seconds. The time gets longer as the advance loops move farther away from the stop bar as speeds increase. There is a lot of engineering that goes into where they go.
EDIT: here its the section of the 2003 Rev. 2 MUTCD that is currently in effect and applies:
Section 4D.26 Yellow Change and Red Clearance Intervals
Standard:
01 A steady yellow signal indication shall be displayed following every CIRCULAR GREEN or GREEN ARROW signal indication and following every flashing YELLOW ARROW or flashing RED ARROW signal indication displayed as a part of a steady mode operation. This requirement shall not apply when a CIRCULAR GREEN, a flashing YELLOW ARROW, or a flashing RED ARROW signal indication is followed immediately by a GREEN ARROW signal indication.
02 The exclusive function of the yellow change interval shall be to warn traffic of an impending change in the right-of-way assignment.
03 The duration of the yellow change interval shall be determined using engineering practices.
Support:
04
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4d.htm#section4D05Section 4D.05 contains provisions regarding the display of steady CIRCULAR YELLOW signal indications to approaches from which drivers are allowed to make permissive left turns.
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4d.htm#section4D05
Guidance:
05 When indicated by the application of engineering practices, the yellow change interval should be followed by a red clearance interval to provide additional time before conflicting traffic movements, including pedestrians, are released.
Standard:
06 When used, the duration of the red clearance interval shall be determined using engineering practices.
Support:
07 Engineering practices for determining the duration of yellow change and red clearance intervals can be found in ITE's "Traffic Control Devices Handbook" and in ITE's "Manual of Traffic Signal Design" (see
https://mutcd.fhwa.dot.gov/htm/2009/part1/part1a.htm#section1A11Section 1A.11).
https://mutcd.fhwa.dot.gov/htm/2009/part1/part1a.htm#section1A11
Standard:
08 The durations of yellow change intervals and red clearance intervals shall be consistent with the determined values within the technical capabilities of the controller unit.
09
The duration of a yellow change interval shall not vary on a cycle-by-cycle basis within the same signal timing plan.
10 Except as provided in
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4d.htm#section4D26_para12Paragraph 12, the duration of a red clearance interval shall not be decreased or omitted on a cycle-by-cycle basis within the same signal timing plan.
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4d.htm#section4D26_para12
Option:
11 The duration of a red clearance interval may be extended from its predetermined value for a given cycle based upon the detection of a vehicle that is predicted to violate the red signal indication.
12 When an actuated signal sequence includes a signal phase for permissive/protected (lagging) left-turn movements in both directions, the red clearance interval may be shown during those cycles when the lagging left-turn signal phase is skipped and may be omitted during those cycles when the lagging left-turn signal phase is shown.
13 The duration of a yellow change interval or a red clearance interval may be different in different signal timing plans for the same controller unit.
Guidance:
14 A yellow change interval should have a minimum duration of 3 seconds and a maximum duration of 6 seconds. The longer intervals should be reserved for use on approaches with higher speeds.
15 Except when clearing a one-lane, two-way facility (see <A href="
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4h.htm#section4H02https://mutcd.fhwa.dot.gov/htm/2009/part4/part4h.htm#section4H02">Section
https://mutcd.fhwa.dot.gov/htm/2009/part4/part4h.htm#section4H024H.02) or when clearing an exceptionally wide intersection, a red clearance interval should have a duration not exceeding 6 seconds.
I would check out what the local law is, but I suspect the urban understanding is not what the law actually says.