TIE= Tarjeta de identitad de extranjero = your physical identity card (with your NIE printed on it). It is a very important card - it is your residence permit. You should have it with you at all times, as it is proof that you are residing in the country legally. Its duration varies on every case. This applies to third-country residents (Non-Europeans).
NIE = Numero de identitad de extranjero = your permanent foreigner identification number. Usually, this number is assigned at the time your work and residence permit is approved. Often times this will be printed on your visa; it will also be printed on your TIE (the actual physical card). It is a very important number that you will likely memorize, as you utilize it frequently.
NOTE: Europeans will only have a NIE (certificado del registro de ciudadano de la Unión). It will have not have a picture on it, as for identification purposes, you have to show the national identity cards.