There is no obligation upon you to take part in a line up. The police cannot force you. If you refuse to go into a line up it is likely the police will take a photograph of you and show the witness that photograph together with other photographs of other people.
The law makes it clear that police have to give a suspect the opportunity to take part in an identification parade (line up) before they can use other forms of identification evidence (photos). If the suspect refuses to go in a line up, the police can use other forms of identification evidence (photos, crowd scene).
If the police do not give the suspect the opportunity to take part in a line up any other form of identification evidence may not be allowed into evidence.
The reality is that the Police will want to avoid doing a line up. Generally they want you to refuse because it will cause them more work and is hard to organise.
Identification evidence is often weak and it is very important that you speak to a lawyer before going in a line up.