The US pried Japan open. Japan had evicted Westerners after some exposure to early industrial ideas from Dutch missionaries, but as Western presence expanded, Japan evicted all Westerners except for a Dutch enclave at Nagasaki. This period of self-imposed isolation lasted until 1853, when Commodore Perry came and forced Japan to join the global economy. For a good recounting of these events, see this. If you have access to more databases than I do, you might find this interesting.
The question of myth in the Japanese context is very different than American myths in Africa. Because the US simply opened (versus settled) Japan, myth creation simply wasn't as necessary. Yes, there was probably racism towards the Japanese like there was towards most minority groups during that time period, but the government didn't need to create an image of the Japanese as needy, backwards, or inferior to support their mission. As long as the public was aware the Japanese market held great economic potential, an economic mission was justified. If, for the growing empire, the means justify the ends, then so do the myths.