Even in August, Japan still kept garrisons in China totalling around 3 million men. They were second-line troops and poorly equipped, yes, but why did Japan not recall everyone to defend the home islands as the US invasion draws near?
I can think of a number of reasons, but they fall under two categories: 1) Logistics and 2) Morale
With the Japanese islands cut off from the outside world, the Japanese islands could not produce enough food to feed its population and the soldiers already on the islands. Pulling another 2-3 million troops from China would have only aggravated that problem. Whereas the soldiers in China could feed themselves and "smuggle" some food to the home islands past the naval blockade. Finally, as Pieter pointed out, holding China (and its food-producing areas) prevented the Allies from easily capturing them, and using the food and other supplies for the invasion (instead of bringing them thousands of miles from the United States).
With the Allied blockade, not all of the Japanese forces would have been successfully repatriated. Perhaps half of them might have been sunk by Allied ships. Having half the China army at the bottom of the sea would have probably done more damage to morale than the (shell-shocked) survivors would have contributed to the defense. And oddly enough, when a country is threatened with invasion, having an overseas "colony" may be a consolation; at least someone else is worse off than you are.
How many troop transports did the Japanese retain at that point in time? What success would they have had by then in protecting such a cargo from US submarines, surface vessels and air craft while it shuttled across?
The East China Sea is a far cry from the Straights of Dover after all, and that wasn't called The Miracle of Dunkirk for no reason. The North Sea was amazingly calm for three days, and the Germans were caught unprepared by having out-run their supplies again.
Also the economic and geographic resources that Japan continued to occupy in China would have simplified the US logistics for an invasion considerably.
In every battle there is a correct strength to devote to each objective, according to the plan adopted. Any serious criticism of the adopted plan would require detailed knowledge of, and analysis of, the Japanese intentions for defence of the home islands. Certainly US casualty estimates for the invasion do not recognize any major flaw.