@@ -44,7 +44,7 @@ void compute_cell_info(int* cell_info,
4444 const float & rcut,
4545 const deepmd::Region<FPTYPE>& region);
4646
47- #if GOOGLE_CUDA
47+ #if GOOGLE_CUDA || TENSORFLOW_USE_ROCM
4848// normalize coords
4949// output:
5050// coord
@@ -83,47 +83,6 @@ int copy_coord_gpu(FPTYPE* out_c,
8383 const int & total_cellnum,
8484 const int * cell_info,
8585 const deepmd::Region<FPTYPE>& region);
86- #endif // GOOGLE_CUDA
87-
88- #if TENSORFLOW_USE_ROCM
89- // normalize coords
90- // output:
91- // coord
92- // input:
93- // natom, box_info: boxt, rec_boxt
94- template <typename FPTYPE>
95- void normalize_coord_gpu (FPTYPE* coord,
96- const int natom,
97- const deepmd::Region<FPTYPE>& region);
98-
99- // copy coordinates
100- // outputs:
101- // out_c, out_t, mapping, nall,
102- // int_data(temp cuda
103- // memory):idx_map,idx_map_noshift,temp_idx_order,loc_cellnum_map,total_cellnum_map,mask_cellnum_map,
104- // cell_map,cell_shift_map,sec_loc_cellnum_map,sec_total_cellnum_map,loc_clist
105- // inputs:
106- // in_c, in_t, nloc, mem_nall, loc_cellnum, total_cellnum, cell_info,
107- // box_info mem_nall is the size of allocated memory for out_c, out_t,
108- // mapping
109- // returns
110- // 0: succssful
111- // 1: the memory is not large enough to hold all copied coords and types.
112- // i.e. nall > mem_nall
113- template <typename FPTYPE>
114- int copy_coord_gpu (FPTYPE* out_c,
115- int * out_t ,
116- int * mapping,
117- int * nall,
118- int * int_data,
119- const FPTYPE* in_c,
120- const int * in_t ,
121- const int & nloc,
122- const int & mem_nall,
123- const int & loc_cellnum,
124- const int & total_cellnum,
125- const int * cell_info,
126- const deepmd::Region<FPTYPE>& region);
127- #endif // TENSORFLOW_USE_ROCM
86+ #endif // GOOGLE_CUDA || TENSORFLOW_USE_ROCM
12887
12988} // namespace deepmd
0 commit comments