According to the definition of the FAA it is a recommended procedure, so there is generally no need to follow it.
OBSTACLE DEPARTURE PROCEDURE (ODP)- A preplanned instrument flight rule (IFR) departure procedure printed for pilot use in textual or graphic form to provide obstruction clearance via the least onerous route from the terminal area to the appropriate en route structure. ODPs are recommended for obstruction clearance and may be flown without ATC clearance unless an alternate departure procedure (SID or radar vector) has been specifically assigned by ATC. (Source: FAA Pilot/Controller Glossary)
According to FAR 91.175 you are responsible to ensure sufficient obstacle clearance if the airport is IFR (of course also if the airport is VFR).
(f) Civil airport takeoff minimums. This paragraph applies to persons operating an aircraft under part 121, 125, 129, or 135 of this chapter.
(1) Unless otherwise authorized by the FAA, no pilot may takeoff from a civil airport under IFR unless the weather conditions at time of takeoff are at or above the weather minimums for IFR takeoff prescribed for that airport under part 97 of this chapter.
(2) If takeoff weather minimums are not prescribed under part 97 of this chapter for a particular airport, the following weather minimums apply to takeoffs under IFR:
(i) For aircraft, other than helicopters, having two engines or less--1 statute mile visibility.
(ii) For aircraft having more than two engines--1/2 statute mile visibility.
(iii) For helicopters--1/2 statute mile visibility.
(3) Except as provided in paragraph (f)(4) of this section, no pilot may takeoff under IFR from a civil airport having published obstacle departure procedures (ODPs) under part 97 of this chapter for the takeoff runway to be used, unless the pilot uses such ODPs.
(4) Notwithstanding the requirements of paragraph (f)(3) of this section, no pilot may takeoff from an airport under IFR unless:
(i) For part 121 and part 135 operators, the pilot uses a takeoff obstacle clearance or avoidance procedure that ensures compliance with the applicable airplane performance operating limitations requirements under part 121, subpart I or part 135, subpart I for takeoff at that airport; or
(ii) For part 129 operators, the pilot uses a takeoff obstacle clearance or avoidance procedure that ensures compliance with the airplane performance operating limitations prescribed by the State of the operator for takeoff at that airport.
In this case it seems to be the easiest way to follow the ODP, but it's not binding.
Lnafziger correctly commented that this is not applicable for part 91 operation. That's why I like to add a part of this Article, which I've found on the AOPA website, to my answer.
[...] We cannot assume that ATC will assign any special routing or altitude based on the ODP. They expect the pilot to fly the procedure if necessary without further clearance. FAA Order 7110.65R, Air Traffic Control--the controller's handbook--states, "If a published IFR departure is not included in an ATC clearance, compliance with such a procedure is the pilot's prerogative." In other words, you have to decide whether you need to follow a specific route or procedure and fly accordingly. Now, we might think this is wrong, dangerous, and dumb, but it is the way procedures are arranged.[...]
According to all this information ATC would expect you to follow this procedure, at least in IMC. If you like to fly it in VMC and it does not disagree with your ATC clearance you are also welcome to do so. If there is any confusion I tend to ask and clarify the situation.
In most cases an ODP says that you should climb on runway heading at least until passing xxx feet before turning in a direction. I would always comply with it and if there is severe CAVOK and ATC then asks me to turn earlier, I would do it, so everyone is happy and on the safe side.