If one knowingly ate non-kosher beef, but didn’t think/realize that it could cause karet due to forbidden fats or blood, do they still get karet if these forbidden items were in fact in the meat?
To 'earn' the karet punishment one must sin b'meizid - knowingly (First Rashi in Masecta Kritut). The required knowledge is a. knowing that the action is a prohibited at the time, and b. knowing the punishment for the sin.
There are two prerequisites for a beit din (Jewish court of law) to administer any kind of physical punishment (whether flogging of death, excluding enforcement of Rabbinical laws), a. there are two kosher witnesses to the deed (Deuteronomy 17,6). b. the transgressor was warned (Talmud Sanhedrin 40b) that a. the deed about to be committed is prohibited at the time. b. that the deed carries a specific penalty (Rambam Sanhedrin 12,2).
The reason the warning is required is to differentiate between an accidental (shogeg) and an intentional (meizid) violation. That is apparent from the Talmud in several places, such as Sanhedrin 8b, where Rabbi Yossi says that a scholar can be punished without prior warning since he knows that the deed is indeed prohibited.