No. You can be quite rational while practicing racism.
Take this definition:
A common trait among the sociological definitions of racism is that they define racism backwards from its results. The results of racism include, among other things, social inequality based on apparent racial affiliation. Thus, anything that causes social inequality becomes racism, regardless of intent. This allows the possibility of unconscious racism, evident in the definition offered by the Christian Anti-Racism Initiative in South Africa:
Racism is essentially a conscious or unconscious belief in the inherent superiority of one race over another\others and thereby the right by that race to use power to dominate.[5]
Daniel Hindes - Essasys
Or this one:
Racism
Is any action or attitude, conscious or unconscious, that subordinates an individual or group based on skin colour or race. It can be enacted individually or institutionally.
Source: US Civil Rights Commission
Defining Race Racism and Racial Discrimination
You can be quite rational and do these things.
Some people take loss of revenue as a cost of doing business, prioritizing one one thing over another. Sometimes this make very good sense. But it isn't irrational in and of itself. It's no more rational or irrational to ignore someone clearly stealing a bike.