Edit: #1: we can take as read that people were racist back in 1900
Because s.25 is referring specifically to voting and how to decide on the number of members in the House of Representatives which relies on numbers of people being counted in the nation and each state.
For the purposes of the last section, if by the law of any State all persons of any race are disqualified from voting at elections for the more numerous House of the Parliament of the State, then, in reckoning the number of the people of the State or of the Commonwealth, persons of that race resident in that State shall not be counted.
This is referring to s.24 which says:
The number of members chosen in the several States shall be in proportion to the respective numbers of their people, and shall, until the Parliament otherwise provides, be determined, whenever necessary, in the following manner: (i) a quota shall be ascertained by dividing the number of the people of the Commonwealth, as shown by the latest statistics of the Commonwealth, by twice the number of the senators; (ii) the number of members to be chosen in each State shall be determined by dividing the number of the people of the State, as shown by the latest statistics of the Commonwealth, by the quota; and if on such division there is a remainder greater than one-half of the quota, one more member shall be chosen in the State.
So s.25 is about how to calculate this stuff taking into account indigenous Australians who weren't counted as people and in many cases had no voting rights, but it also reflects how some states were banning other ethnic groups, primarily Chinese Australians, but many other non-white groups who had come across in the 1850s to the Victorian gold rush.
When it comes to s.127 it refers only to indigenous Australians in relation to statistical data and the counting of people in a state, presumably for things like the census, questions of tax and things like that.
tl;dr - s.25 is about counting and voting for the House of Reps which excluded several groups of non-white Australians, including but not limited to indigenous Australians, but s.127 is about counting numbers of people inside a state for any reason.