There are many lines. Some lines are drawn by the law, other lines are drawn by the society we live in and/or our individual ethical norms.
If we have collectively decided that intelligence is a factor when deciding whether an animal can be eaten by humans, then it's a perfectly logical conclusion for many people that eating octopuses is disgraceful.