It depends. The one I went to, teams formed around the ideas - everyone pitched an idea, then you had to go mingle with people to get votes, then the top ten were the ideas that most people worked on.
Usually a couple of teams actually stay together for over a month, most usually fizzle after the weekend.
The one I went to tended to be a little more business-oriented than I liked (the winning team didn't write a line of code), so maybe be careful at first if that's not what you're looking for.
I think it's worth going to for at least one day. You aren't (or shouldn't be) bound to sticking with it the entire weekend.