Discrimination can certainly be a failure to see someone as a whole person. When someone is discriminated against based on a certain characteristic, such as their race, gender, or sexuality, it is often because the discriminator is unable or unwilling to see beyond that characteristic and recognize the full complexity of the person.
For example, someone might discriminate against a person of a certain race because they have been conditioned to see that race in a certain way, rather than seeing the individual as a unique person with their own experiences and qualities. Similarly, someone might discriminate against a person because of their gender, assuming that they possess certain traits or characteristics that are associated with that gender, rather than recognizing the full range of traits and qualities that any individual may possess.
It is important to recognize that discrimination is not simply a matter of failing to see someone as a whole person, but is often deeply embedded in social and cultural structures that perpetuate inequality and prejudice. However, seeing people as whole individuals with their own unique experiences and qualities is an important step towards combating discrimination and creating a more equitable society.