Two countries with similar population, ample space and natural resources, won their independence from the imperialists around the same time, started out at around the same level of poverty and underdevelopment (China was actually slightly poorer and even less developed), yet the socialist one in the long run performed noticeably better. Now visiting the two countries the difference is night and day, you don't need GDP graphs to see it.
Not that GDP is a perfect measure of progress for a society... in fact it leaves out a lot and it can be inflated artificially by financialization and rent-seeking in neoliberal systems (not the case in China).
What you don't see in this is the incredible development that took place in China pre-1980s starting in the 1950s in ways that was not reflected in GDP but laid the groundwork for the future economic rise: education and literacy rates, industrialization, infrastructure, housing, food security, etc. This is why socialism will win. It is the only viable model for the global majority to escape their colonial imposed underdevelopment.
Unfortunately i don't really have much in-depth knowledge on this subject of how agriculture is run in China these days and how centralized it is. One thing i do know is that originally after the revolution a massive land redistribution took place, the biggest in the history of the world in fact, and basically everyone who lived in a rural area got their own plot of land. I would assume though that those plots were fairly small and that a large portion of the land was still farmed by collectives, and that over time consolidation into larger and more centrally controlled agricultural enterprises took place. But as i say, i haven't read much on this subject, so it would be very interesting if someone were to do a deep dive on this for us.
I think that you are right about the broader mechanisms at work here that explain the disparity between India and China, namely that in China a lot more was re-invested into increasing the productivity of the land because there was a lot more central planning and less short term profit seeking. And yes there probably are more small farmers in India than in China nowadays (though again i don't have the data to back it up), but i'm not sure how big the impact of that disparity is. Because even when you do have land consolidated under large agribusiness corporations in global south countries, they still tend to be very inefficient, unwilling to invest in long term productivity or sustainability, and focused on extracting as much value as fast as possible at the expense of the people and the land.