Am I racist if I only consider white people European and black people African?

If a black person had at least one white ancestor I would consider them partly European or if a person with white skin had a black ancestor I would consider them partly black.

If a black person with zero white ancestors was born in a European country I personally wouldn’t consider them European.

Also if a white person with zero black ancestors was born in an African country I personally wouldn’t consider them African.

Am I racist if I only consider white people European and black people African?
Post Opinion