They look similar, but they are different. The reason of difference in structure is related to making sentence in Korean(grammar).
One seem analogous to another because of ellipsis of sentence component in sentence. I think you might saw the other sentences before and after these sentences. But as there's no context(before and after each sentence), let me explain it with full sentenfce without omitting sentence components.
'(내가) 아무리 생각해도', 난 너를 좋아하는 것 같아.
'However I ponder', I think I fall in love with you.
You can see subject 내가=I is quite often omitted if it's with other sentences. 내가 is omitted if sense is understandable by the context.
"너를 아무리 (지우려) 생각해도 난 네가 잊혀지지 않아.
However I try to (remove) you from my mind, I can't forget you.
Similarly, verb 지우려—the basic form of 지우려 is 지우다(=remove, erase)—was omitted.
네가=you, can't forget=잊혀지지 않아