update initialization in demo