请教一个关于vulkan的error

请教一个error,Mac系统用pycharm跑代码,出现vulkan有俩,需要指定,怎么指定呀

objc[1562]: Class MVKBlockObserver is implemented in both /usr/local/lib/libMoltenVK.dylib (0x11c6e4f38) and /Library/Frameworks/Python.framework/Versions/3.9/lib/python3.9/site-packages/taichi/_lib/runtime/libMoltenVK.dylib (0x11cdd6938). One of the two will be used. Which one is undefined.
[mvk-info] MoltenVK version 1.1.8, supporting Vulkan version 1.1.204.

你可以卸载VulkanSDK,然后再跑你的代码试试?

我手动卸载了Vulkan SDK,然后还是提示俩,我又到提示的系统根目录下把 ’’’/usr/local/lib/libMoltenVK.dylib’’’ 手动删除了,然后不提示俩了,不过提示另外的一堆提示,这些提示在之前也是有的。提示如下:

[mvk-info] MoltenVK version 1.1.8, supporting Vulkan version 1.1.204.
	The following 72 Vulkan extensions are supported:
		VK_KHR_16bit_storage v1
		VK_KHR_8bit_storage v1
		VK_KHR_bind_memory2 v1
		VK_KHR_create_renderpass2 v1
		VK_KHR_dedicated_allocation v3
		VK_KHR_depth_stencil_resolve v1
		VK_KHR_descriptor_update_template v1
		VK_KHR_device_group v4
		VK_KHR_device_group_creation v1
		VK_KHR_driver_properties v1
		VK_KHR_external_fence v1
		VK_KHR_external_fence_capabilities v1
		VK_KHR_external_memory v1
		VK_KHR_external_memory_capabilities v1
		VK_KHR_external_semaphore v1
		VK_KHR_external_semaphore_capabilities v1
		VK_KHR_get_memory_requirements2 v1
		VK_KHR_get_physical_device_properties2 v2
		VK_KHR_get_surface_capabilities2 v1
		VK_KHR_imageless_framebuffer v1
		VK_KHR_image_format_list v1
		VK_KHR_maintenance1 v2
		VK_KHR_maintenance2 v1
		VK_KHR_maintenance3 v1
		VK_KHR_multiview v1
		VK_KHR_portability_subset v1
		VK_KHR_push_descriptor v2
		VK_KHR_relaxed_block_layout v1
		VK_KHR_sampler_mirror_clamp_to_edge v3
		VK_KHR_sampler_ycbcr_conversion v14
		VK_KHR_shader_draw_parameters v1
		VK_KHR_shader_float16_int8 v1
		VK_KHR_shader_subgroup_extended_types v1
		VK_KHR_storage_buffer_storage_class v1
		VK_KHR_surface v25
		VK_KHR_swapchain v70
		VK_KHR_swapchain_mutable_format v1
		VK_KHR_timeline_semaphore v2
		VK_KHR_uniform_buffer_standard_layout v1
		VK_KHR_variable_pointers v1
		VK_EXT_debug_marker v4
		VK_EXT_debug_report v10
		VK_EXT_debug_utils v2
		VK_EXT_descriptor_indexing v2
		VK_EXT_fragment_shader_interlock v1
		VK_EXT_hdr_metadata v2
		VK_EXT_host_query_reset v1
		VK_EXT_image_robustness v1
		VK_EXT_inline_uniform_block v1
		VK_EXT_memory_budget v1
		VK_EXT_metal_surface v1
		VK_EXT_post_depth_coverage v1
		VK_EXT_private_data v1
		VK_EXT_robustness2 v1
		VK_EXT_scalar_block_layout v1
		VK_EXT_shader_stencil_export v1
		VK_EXT_shader_viewport_index_layer v1
		VK_EXT_subgroup_size_control v2
		VK_EXT_swapchain_colorspace v4
		VK_EXT_texel_buffer_alignment v1
		VK_EXT_texture_compression_astc_hdr v1
		VK_EXT_vertex_attribute_divisor v3
		VK_AMD_gpu_shader_half_float v2
		VK_AMD_negative_viewport_height v1
		VK_AMD_shader_image_load_store_lod v1
		VK_AMD_shader_trinary_minmax v1
		VK_IMG_format_pvrtc v1
		VK_INTEL_shader_integer_functions2 v1
		VK_GOOGLE_display_timing v1
		VK_MVK_macos_surface v3
		VK_MVK_moltenvk v33
		VK_NV_glsl_shader v1
[mvk-info] GPU device:
		model: Intel(R) Iris(TM) Graphics 550
		type: Integrated
		vendorID: 0x8086
		deviceID: 0x1927
		pipelineCacheUUID: 0000277C-0A0F-07D2-0000-000000000000
	supports the following Metal Versions, GPU's and Feature Sets:
		Metal Shading Language 2.3
		GPU Family Mac 2
		GPU Family Mac 1
		GPU Family Common 3
		GPU Family Common 2
		GPU Family Common 1
		macOS GPU Family 2 v1
		macOS GPU Family 1 v4
		macOS GPU Family 1 v3
		macOS GPU Family 1 v2
		macOS GPU Family 1 v1
[mvk-info] Created VkInstance for Vulkan version 1.0.0, as requested by app, with the following 0 Vulkan extensions enabled:
[mvk-info] MoltenVK version 1.1.8, supporting Vulkan version 1.1.204.
	The following 72 Vulkan extensions are supported:
		VK_KHR_16bit_storage v1
		VK_KHR_8bit_storage v1
		VK_KHR_bind_memory2 v1
		VK_KHR_create_renderpass2 v1
		VK_KHR_dedicated_allocation v3
		VK_KHR_depth_stencil_resolve v1
		VK_KHR_descriptor_update_template v1
		VK_KHR_device_group v4
		VK_KHR_device_group_creation v1
		VK_KHR_driver_properties v1
		VK_KHR_external_fence v1
		VK_KHR_external_fence_capabilities v1
		VK_KHR_external_memory v1
		VK_KHR_external_memory_capabilities v1
		VK_KHR_external_semaphore v1
		VK_KHR_external_semaphore_capabilities v1
		VK_KHR_get_memory_requirements2 v1
		VK_KHR_get_physical_device_properties2 v2
		VK_KHR_get_surface_capabilities2 v1
		VK_KHR_imageless_framebuffer v1
		VK_KHR_image_format_list v1
		VK_KHR_maintenance1 v2
		VK_KHR_maintenance2 v1
		VK_KHR_maintenance3 v1
		VK_KHR_multiview v1
		VK_KHR_portability_subset v1
		VK_KHR_push_descriptor v2
		VK_KHR_relaxed_block_layout v1
		VK_KHR_sampler_mirror_clamp_to_edge v3
		VK_KHR_sampler_ycbcr_conversion v14
		VK_KHR_shader_draw_parameters v1
		VK_KHR_shader_float16_int8 v1
		VK_KHR_shader_subgroup_extended_types v1
		VK_KHR_storage_buffer_storage_class v1
		VK_KHR_surface v25
		VK_KHR_swapchain v70
		VK_KHR_swapchain_mutable_format v1
		VK_KHR_timeline_semaphore v2
		VK_KHR_uniform_buffer_standard_layout v1
		VK_KHR_variable_pointers v1
		VK_EXT_debug_marker v4
		VK_EXT_debug_report v10
		VK_EXT_debug_utils v2
		VK_EXT_descriptor_indexing v2
		VK_EXT_fragment_shader_interlock v1
		VK_EXT_hdr_metadata v2
		VK_EXT_host_query_reset v1
		VK_EXT_image_robustness v1
		VK_EXT_inline_uniform_block v1
		VK_EXT_memory_budget v1
		VK_EXT_metal_surface v1
		VK_EXT_post_depth_coverage v1
		VK_EXT_private_data v1
		VK_EXT_robustness2 v1
		VK_EXT_scalar_block_layout v1
		VK_EXT_shader_stencil_export v1
		VK_EXT_shader_viewport_index_layer v1
		VK_EXT_subgroup_size_control v2
		VK_EXT_swapchain_colorspace v4
		VK_EXT_texel_buffer_alignment v1
		VK_EXT_texture_compression_astc_hdr v1
		VK_EXT_vertex_attribute_divisor v3
		VK_AMD_gpu_shader_half_float v2
		VK_AMD_negative_viewport_height v1
		VK_AMD_shader_image_load_store_lod v1
		VK_AMD_shader_trinary_minmax v1
		VK_IMG_format_pvrtc v1
		VK_INTEL_shader_integer_functions2 v1
		VK_GOOGLE_display_timing v1
		VK_MVK_macos_surface v3
		VK_MVK_moltenvk v33
		VK_NV_glsl_shader v1
[mvk-info] GPU device:
		model: Intel(R) Iris(TM) Graphics 550
		type: Integrated
		vendorID: 0x8086
		deviceID: 0x1927
		pipelineCacheUUID: 0000277C-0A0F-07D2-0000-000000000000
	supports the following Metal Versions, GPU's and Feature Sets:
		Metal Shading Language 2.3
		GPU Family Mac 2
		GPU Family Mac 1
		GPU Family Common 3
		GPU Family Common 2
		GPU Family Common 1
		macOS GPU Family 2 v1
		macOS GPU Family 1 v4
		macOS GPU Family 1 v3
		macOS GPU Family 1 v2
		macOS GPU Family 1 v1
[mvk-info] Created VkInstance for Vulkan version 1.1.204, as requested by app, with the following 5 Vulkan extensions enabled:
		VK_KHR_external_memory_capabilities v1
		VK_KHR_external_semaphore_capabilities v1
		VK_KHR_get_physical_device_properties2 v2
		VK_KHR_surface v25
		VK_EXT_debug_utils v2
[E 04/28/22 23:00:35.800 220067] Received signal 11 (Segmentation fault: 11)



                            * Taichi Core - Stack Traceback *                             
==========================================================================================
|                       Module |  Offset | Function                                      |
|----------------------------------------------------------------------------------------|
*               taichi_core.so |     126 | taichi::Logger::error(std::__1::basic_string< |
                                         | char, std::__1::char_traits<char>, std::__1:: |
                                         | allocator<char> > const&, bool)               |
*               taichi_core.so |     228 | taichi::(anonymous namespace)::signal_handler |
                                         | (int)                                         |
*     libsystem_platform.dylib |      29 | (null)                                        |
*                          ??? | 150542336 | (null)                                      |
*            libMoltenVK.dylib |     228 | (null)                                        |
*               taichi_core.so |      37 | taichi::lang::vulkan::VulkanDevice::~VulkanDe |
                                         | vice()                                        |
*               taichi_core.so |      14 | taichi::lang::vulkan::VulkanDevice::~VulkanDe |
                                         | vice()                                        |
*               taichi_core.so |     769 | taichi::lang::vulkan::VulkanDeviceCreator::Vu |
                                         | lkanDeviceCreator(taichi::lang::vulkan::Vulka |
                                         | nDeviceCreator::Params const&)                |
*               taichi_core.so |    1434 | taichi::ui::vulkan::AppContext::init(taichi:: |
                                         | lang::Program*, GLFWwindow*, taichi::ui::AppC |
                                         | onfig const&)                                 |
*               taichi_core.so |      22 | taichi::ui::vulkan::Renderer::init(taichi::la |
                                         | ng::Program*, GLFWwindow*, taichi::ui::AppCon |
                                         | fig const&)                                   |
*               taichi_core.so |     204 | taichi::ui::vulkan::Window::init(taichi::lang |
                                         | ::Program*, taichi::ui::AppConfig const&)     |
*               taichi_core.so |     185 | taichi::ui::vulkan::Window::Window(taichi::la |
                                         | ng::Program*, taichi::ui::AppConfig const&)   |
*               taichi_core.so |     305 | taichi::ui::PyWindow::PyWindow(taichi::lang:: |
                                         | Program*, std::__1::basic_string<char, std::_ |
                                         | _1::char_traits<char>, std::__1::allocator<ch |
                                         | ar> >, pybind11::tuple, bool, bool, std::__1: |
                                         | :basic_string<char, std::__1::char_traits<cha |
                                         | r>, std::__1::allocator<char> >, taichi::Arch |
                                         | , bool)                                       |
*               taichi_core.so |     183 | taichi::ui::PyWindow* pybind11::detail::initi |
                                         | mpl::construct_or_initialize<taichi::ui::PyWi |
                                         | ndow, taichi::lang::Program*, std::__1::basic |
                                         | _string<char, std::__1::char_traits<char>, st |
                                         | d::__1::allocator<char> >, pybind11::tuple, b |
                                         | ool, bool, std::__1::basic_string<char, std:: |
                                         | __1::char_traits<char>, std::__1::allocator<c |
                                         | har> >, taichi::Arch, bool, 0>(taichi::lang:: |
                                         | Program*&&, std::__1::basic_string<char, std: |
                                         | :__1::char_traits<char>, std::__1::allocator< |
                                         | char> >&&, pybind11::tuple&&, bool&&, bool&&, |
                                         |  std::__1::basic_string<char, std::__1::char_ |
                                         | traits<char>, std::__1::allocator<char> >&&,  |
                                         | taichi::Arch&&, bool&&)                       |
*               taichi_core.so |     179 | pybind11::class_<taichi::ui::PyWindow> pybind |
                                         | 11::detail::argument_loader<pybind11::detail: |
                                         | :value_and_holder&, taichi::lang::Program*, s |
                                         | td::__1::basic_string<char, std::__1::char_tr |
                                         | aits<char>, std::__1::allocator<char> >, pybi |
                                         | nd11::tuple, bool, bool, std::__1::basic_stri |
                                         | ng<char, std::__1::char_traits<char>, std::__ |
                                         | 1::allocator<char> >, taichi::Arch, bool>::ca |
                                         | ll_impl<void, void pybind11::detail::initimpl |
                                         | ::constructor<taichi::lang::Program*, std::__ |
                                         | 1::basic_string<char, std::__1::char_traits<c |
                                         | har>, std::__1::allocator<char> >, pybind11:: |
                                         | tuple, bool, bool, std::__1::basic_string<cha |
                                         | r, std::__1::char_traits<char>, std::__1::all |
                                         | ocator<char> >, taichi::Arch, bool>::execute< |
                                         | pybind11::class_<taichi::ui::PyWindow>, 0>(py |
                                         | bind11::class_<taichi::ui::PyWindow>&)::'lamb |
                                         | da'(pybind11::detail::value_and_holder&, taic |
                                         | hi::lang::Program*, std::__1::basic_string<ch |
                                         | ar, std::__1::char_traits<char>, std::__1::al |
                                         | locator<char> >, pybind11::tuple, bool, bool, |
                                         |  std::__1::basic_string<char, std::__1::char_ |
                                         | traits<char>, std::__1::allocator<char> >, ta |
                                         | ichi::Arch, bool)&, 0ul, 1ul, 2ul, 3ul, 4ul,  |
                                         | 5ul, 6ul, 7ul, 8ul, pybind11::detail::void_ty |
                                         | pe>(void pybind11::detail::initimpl::construc |
                                         | tor<taichi::lang::Program*, std::__1::basic_s |
                                         | tring<char, std::__1::char_traits<char>, std: |
                                         | :__1::allocator<char> >, pybind11::tuple, boo |
                                         | l, bool, std::__1::basic_string<char, std::__ |
                                         | 1::char_traits<char>, std::__1::allocator<cha |
                                         | r> >, taichi::Arch, bool>::execute<pybind11:: |
                                         | class_<taichi::ui::PyWindow>, 0>(pybind11::cl |
                                         | ass_<taichi::ui::PyWindow>&)::'lambda'(pybind |
                                         | 11::detail::value_and_holder&, taichi::lang:: |
                                         | Program*, std::__1::basic_string<char, std::_ |
                                         | _1::char_traits<char>, std::__1::allocator<ch |
                                         | ar> >, pybind11::tuple, bool, bool, std::__1: |
                                         | :basic_string<char, std::__1::char_traits<cha |
                                         | r>, std::__1::allocator<char> >, taichi::Arch |
                                         | , bool)&, std::__1::integer_sequence<unsigned |
                                         |  long, 0ul, 1ul, 2ul, 3ul, 4ul, 5ul, 6ul, 7ul |
                                         | , 8ul>, pybind11::detail::void_type&&) &&     |
*               taichi_core.so |      76 | void pybind11::cpp_function::initialize<void  |
                                         | pybind11::detail::initimpl::constructor<taich |
                                         | i::lang::Program*, std::__1::basic_string<cha |
                                         | r, std::__1::char_traits<char>, std::__1::all |
                                         | ocator<char> >, pybind11::tuple, bool, bool,  |
                                         | std::__1::basic_string<char, std::__1::char_t |
                                         | raits<char>, std::__1::allocator<char> >, tai |
                                         | chi::Arch, bool>::execute<pybind11::class_<ta |
                                         | ichi::ui::PyWindow>, 0>(pybind11::class_<taic |
                                         | hi::ui::PyWindow>&)::'lambda'(pybind11::detai |
                                         | l::value_and_holder&, taichi::lang::Program*, |
                                         |  std::__1::basic_string<char, std::__1::char_ |
                                         | traits<char>, std::__1::allocator<char> >, py |
                                         | bind11::tuple, bool, bool, std::__1::basic_st |
                                         | ring<char, std::__1::char_traits<char>, std:: |
                                         | __1::allocator<char> >, taichi::Arch, bool),  |
                                         | void, pybind11::detail::value_and_holder&, ta |
                                         | ichi::lang::Program*, std::__1::basic_string< |
                                         | char, std::__1::char_traits<char>, std::__1:: |
                                         | allocator<char> >, pybind11::tuple, bool, boo |
                                         | l, std::__1::basic_string<char, std::__1::cha |
                                         | r_traits<char>, std::__1::allocator<char> >,  |
                                         | taichi::Arch, bool, pybind11::name, pybind11: |
                                         | :is_method, pybind11::sibling, pybind11::deta |
                                         | il::is_new_style_constructor>(pybind11::class |
                                         | _<taichi::ui::PyWindow>&&, void (*)(pybind11: |
                                         | :detail::value_and_holder&, taichi::lang::Pro |
                                         | gram*, std::__1::basic_string<char, std::__1: |
                                         | :char_traits<char>, std::__1::allocator<char> |
                                         |  >, pybind11::tuple, bool, bool, std::__1::ba |
                                         | sic_string<char, std::__1::char_traits<char>, |
                                         |  std::__1::allocator<char> >, taichi::Arch, b |
                                         | ool), pybind11::name const&, pybind11::is_met |
                                         | hod const&, pybind11::sibling const&, pybind1 |
                                         | 1::detail::is_new_style_constructor const&):: |
                                         | 'lambda'(pybind11::detail::function_call&)::o |
                                         | perator()(pybind11::detail::function_call&) c |
                                         | onst                                          |
*               taichi_core.so |    4691 | pybind11::cpp_function::dispatcher(_object*,  |
                                         | _object*, _object*)                           |
*                       Python |      59 | (null)                                        |
*                       Python |     365 | (null)                                        |
*                       Python |     502 | (null)                                        |
*                       Python |     232 | (null)                                        |
*                       Python |     345 | (null)                                        |
*               taichi_core.so |      30 | (null)                                        |
*                       Python |     365 | (null)                                        |
*                       Python |     876 | (null)                                        |
*                       Python |   25219 | (null)                                        |
*                       Python |    2611 | (null)                                        |
*                       Python |     289 | (null)                                        |
*                       Python |     159 | (null)                                        |
*                       Python |     152 | (null)                                        |
*                       Python |     165 | (null)                                        |
*                       Python |     345 | (null)                                        |
*                       Python |     365 | (null)                                        |
*                       Python |     876 | (null)                                        |
*                       Python |   25521 | (null)                                        |
*                       Python |     104 | (null)                                        |
*                       Python |     202 | (null)                                        |
*                       Python |     732 | (null)                                        |
*                       Python |   25219 | (null)                                        |
*                       Python |    2611 | (null)                                        |
*                       Python |     139 | (null)                                        |
*                       Python |     387 | (null)                                        |
*                       Python |     850 | (null)                                        |
*                       Python |    1801 | (null)                                        |
*                       Python |     223 | (null)                                        |
*                       Python |      43 | (null)                                        |
*                         dyld |     462 | (null)                                        |
==========================================================================================


Internal error occurred. Check out this page for possible solutions:
https://docs.taichi.graphics/lang/articles/install

Process finished with exit code 255

Hi @MierDa , 你的问题貌似和我Mac上问题差不多。我提了一个ISSUE,发现应该是MoltenVK的Bug,所以也在MoltenVK上提了一个ISSUE。目前正在Debug中。

是嘛 ,好的,期待早日解决,我是想抱着笔记本去图书馆调试代码 :grnning:

这个代码在Windows下确实没啥问题,是苹果电脑有的

1 个赞