1ef3ad90a3423ed15ca41e0ea4e81012ebe84a9f,catalyst/data/scripts/project_embeddings.py,,main,#Any#Any#,88
Before Change
path.join(args.img_rootpath, name)
for name in df[args.img_col].values
]
img_data = np.stack(
[load_image(name, args.img_size) for name in image_names], axis=0
)
img_data = (
img_data.transpose((0, 3, 1, 2)) / 255.0 // noqa: WPS432
).astype(np.float32)
img_data = torch.from_numpy(img_data)
After Change
assert len(df) == len(features)
if args.num_rows is not None:
indices = np.random.choice(len(df) , args.num_rows)
features = features[indices, :]
df = df.iloc[indices]
if args.img_col is not None:
img_data = _load_image_data(
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 6
Instances Project Name: catalyst-team/catalyst
Commit Name: 1ef3ad90a3423ed15ca41e0ea4e81012ebe84a9f
Time: 2020-08-11
Author: scitator@gmail.com
File Name: catalyst/data/scripts/project_embeddings.py
Class Name:
Method Name: main
Project Name: dask/dask-image
Commit Name: cbbcea8795e8da754a5b3ffb1a08ef66afd84eef
Time: 2018-09-02
Author: jakirkham@gmail.com
File Name: dask_image/ndmeasure/_utils.py
Class Name:
Method Name: _ravel_shape_indices
Project Name: kenshohara/3D-ResNets-PyTorch
Commit Name: 371a1b952acb0d2cccaf3ece7f594763d3f02e03
Time: 2018-11-02
Author: kensho.hara@aist.go.jp
File Name: datasets/videodataset.py
Class Name: VideoDataset
Method Name: __getitem__