Would getting started in research in something outside my specific interest hurt my ability to research in that area later?
I don't see any reason why doing research in one area would prevent you from doing research in another area later on. Many people do several different research projects before they figure out what it is that they want to do and, in some graduate programs, it's even a requirement to do several different "rotation" projects before officially selecting a research group and project.

So I would view any research project as worthwhile. You could find:


you really do like research and find a new area that you'd want to pursue.
you don't like the project but want to try something else.
you really don't like research.


Any of these would be a notable and valuable end result. So don't worry about getting into machine learning later on if you can't get it into it now. Doing research in something that has piqued your interest (at least temporarily) is all that really matters, especially early on in your career.