Skip to content

Commit

Permalink
removed commented code
Browse files Browse the repository at this point in the history
  • Loading branch information
naylor-b committed Aug 6, 2020
1 parent 49f51fe commit 69572ec
Showing 1 changed file with 0 additions and 11 deletions.
11 changes: 0 additions & 11 deletions openmdao/core/group.py
Original file line number Diff line number Diff line change
Expand Up @@ -871,31 +871,20 @@ def _setup_var_data(self):

raw_locs = (locs, locs_disc)
allprocs_raw_locs = self.comm.allgather(raw_locs)
# last_rank = self.comm.size - 1
# owns = self._owning_rank
for type_ in ('input', 'output'):
# own_arr = np.zeros(len(allprocs_abs_names[type_]), dtype=int)
# own_arr_disc = np.zeros(len(allprocs_abs_names_discrete[type_]), dtype=int)
all_locs = np.ones(len(allprocs_abs_names[type_]), dtype=bool)
all_locs_disc = np.ones(len(allprocs_abs_names_discrete[type_]), dtype=bool)
for rank, (loc, loc_disc) in enumerate(allprocs_raw_locs):
all_locs &= loc[type_]
all_locs_disc &= loc_disc[type_]

# # go in reverse order for ownership so that lowest rank owner will be kept
# rev_rank = last_rank - rank
# own_arr[allprocs_raw_locs[rev_rank][0][type_]] = rev_rank
# own_arr_disc[allprocs_raw_locs[rev_rank][1][type_]] = rev_rank

for i, n in enumerate(allprocs_abs_names[type_]):
if not all_locs[i]:
gatherable.add(n)
# owns[n] = own_arr[i]

for i, n in enumerate(allprocs_abs_names_discrete[type_]):
if not all_locs_disc[i]:
gatherable.add(n)
# owns[n] = own_arr_disc[i]

for prom_name, abs_list in allprocs_prom2abs_list['output'].items():
if len(abs_list) > 1:
Expand Down

0 comments on commit 69572ec

Please sign in to comment.