mirror of
				https://github.com/smyalygames/FiniteVolumeGPU.git
				synced 2025-10-31 20:17:41 +01:00 
			
		
		
		
	feat(kernel): add environment condition for importing certain packages
This commit is contained in:
		
							parent
							
								
									3b424d1f5a
								
							
						
					
					
						commit
						d4f2ffc493
					
				| @ -1,2 +1,8 @@ | ||||
| from .cuda_context import CudaContext | ||||
| from .hip_context import HIPContext | ||||
| from os import environ | ||||
| 
 | ||||
| __env_name = 'GPU_LANG' | ||||
| 
 | ||||
| if __env_name in environ and environ.get(__env_name).lower() == "cuda": | ||||
|     from .cuda_context import CudaContext as KernelContext | ||||
| else: | ||||
|     from .hip_context import HIPContext as KernelContext | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user
	 Anthony Berg
						Anthony Berg