People (incl. Japanese who have a overtly rosy picture of Europe) underestimate how important Tokugawa's Sakoku was for the survival of all this.
Indeed, by the time Europe had f*ed up all of Asia in the mid-1800s and reached Japan again, Japan had very high levels of literacy which was perfect for selectively taking of high-culture/industrial-technology of Europe.