The cv window can not be open, how can i solve the problem?

looks like your current opencv installation does not support any gui
(it probably did not find suitable dev-libs, when building opencv)

how did you install this ?