I have a 2x4 nailed to two other 2x4’s protruding from ceiling. This is used to hold up garage door opener. There is a light socket behind it and I wanting to attaching motion sensor socket to it but I believe 2x4 cross piece will block line of sight of sensor. If I was to cut a section of 2x4 cross piece, would it reduce the strength of 2x4 cross piece as far as it being able to hold up garage door opener? Any ideas on motion sensor light socket line of sight issue other than moving socket?
1: Yes it will reduce the strength and depending on how you cut it will determine how much and to what catastrophic point it will fail. A Drilled hole for line of sight is one thing a cut out is another.
The following two comments do not directly answer your question but need to be stated. I am not trying to hurt anyone's feelings by posting them just trying to provide some constructive feedback and I am saying ti because someone needs to say something to help you.
2: That protrusion of 2 x 4's from the ceiling down - that is a terrible (atrocious) mounting for a garage door opener installation! The 2 x 4 should be mounted between above the ceiling between the rafters then your metal mounting for the opener should be on the ceiling side mounted to that 2 x 4 - taking up minimal space and would not be such an eye sore. Of course if this part was done right you would not be asking your question here about your motion sensor.
3: I see that free romex wire running down and I am assuming it is rigged to an electrical outlet for the opener or maybe hooked to it directly - I will state this if you are in the USA ..it is a code violation. You should have that fixed and done right too - install an outlet box in the ceiling and plug your opener power cord into it.
I am not trying to be snobby or anything like that .. normally I don't answer this way but in this case I feel compelled to so that perhaps you will make it right and will not have any issues in the future, especially with your wiring .. like perhaps a fire!
EDIT 3-29-2018 Wiring fix:
would it reduce the strength of 2x4 cross piece as far as it being able to hold up garage door opener?
Yes it would reduce strength. To the point of failure, who knows? You only say that you would "cut a section" but you do not describe exactly how much.
ideas on motion sensor light socket line of sight issue other than moving socket?
Yes, extend the bulb down using a "bulb extender" available at your local hardware store: