Fine line between "figuring it out on my own" and "asking for help" in research labs?
Can you ask your colleague (or whoever wrote the code) a quick question to ascertain whether it's a simple error in the code, or some more complex hurdle that you need to work around?

Don't be afraid to ask for help! You'll be a lot more productive if you ask for help when you really are stuck, rather than waiting too long.

A more experienced mind can usually tell quite quickly whether it's an easy or difficult problem to solve. There's no use banging your head against a brick wall for days if your supervisor has a sledgehammer hidden in his cupboard!