# Organizing package with both gpu- and cpu implemntations

**URL:** <https://discourse.julialang.org/t/organizing-package-with-both-gpu-and-cpu-implemntations/86846>\
**Category:** General Usage\
**Tags:** question\
**Created:** [September 6, 2022, 4:21pm UTC](https://discourse.julialang.org/t/organizing-package-with-both-gpu-and-cpu-implemntations/86846 "2022-09-06T16:21:19Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![ykkan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ykkan/32/14541_2.png) [@ykkan](https://discourse.julialang.org/u/ykkan)\
**Post date:** [September 6, 2022, 4:21pm UTC](https://discourse.julialang.org/t/organizing-package-with-both-gpu-and-cpu-implemntations/86846/1 "2022-09-06T16:21:19Z")

</div>

Hi everyone,  
I am trying to develop a package which provides both gpu-parallelized implementation and cpu-parallelized implementation. How should I organize the project directory? In particular, how should I manage the situation that when users need cpu version, only `using MPI` will be loaded. And when users need gpu version, only `using CUDA` will be loaded. Thank you in advanced.
