No they are not.
They are different chips using mostly similar tech.
I7 does hyper threading differently as it appear as 8 cores to the system.
i5 appears as 4 cores.
Also i7 hasa triple channel memory controller while the i5 is dual channel.
If there are 4 memory slots, it seems like the i5 may be sufficient for an imac.
The i7 being used isn't socket 1366 so no triple channel. However you are right that the i7 does support hyperthreading. Other than that it is just a single multipler difference (+133MHz).