Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

repetitive computation in test data generation #13

Open
marmus12 opened this issue Jan 23, 2019 · 0 comments
Open

repetitive computation in test data generation #13

marmus12 opened this issue Jan 23, 2019 · 0 comments

Comments

@marmus12
Copy link

these lines should be taken out of the for loop of kkk.

if(len(traindata_all)>=12 and traindata_label.shape[-1]==9):
traindata_label_batchNxN[ii,:,:]=traindata_label[image_id,idx_start+crop_half1: idx_start+crop_half1+label_size,idy_start+crop_half1: idy_start+crop_half1+label_size, 4+ix_rd, 4+iy_rd]
elif(len(traindata_label.shape)==5):
traindata_label_batchNxN[ii,:,:]=traindata_label[image_id ,idx_start+crop_half1: idx_start+crop_half1+label_size,idy_start+crop_half1: idy_start+crop_half1+label_size,0,0]
else:
traindata_label_batchNxN[ii,:,:]=traindata_label[image_id ,idx_start+crop_half1: idx_start+crop_half1+label_size,idy_start+crop_half1: idy_start+crop_half1+label_size]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant