code stringlengths 3 6.57k |
|---|
conn.create_vpc_peering_connection(vpc.id, peer_vpc.id) |
Peering(accounts=[self.account.name]) |
watcher.slurp() |
len(item_list) |
format(len(item_list) |
listify(o) |
isinstance(o, list) |
isinstance(o, str) |
isinstance(o, Iterable) |
list(o) |
compose(x, funcs, *args, **kwargs) |
listify(funcs) |
f(x, **kwargs) |
Onehotify() |
__init__(self, vocab_size) |
Tokenizer(num_words=vocab_size) |
__call__(self, item) |
self.tokenizer.sequences_to_matrix([item], mode='binary') |
Padify() |
__init__(self, maxlen) |
__call__(self, item) |
sequence.pad_sequences([item], maxlen=self.maxlen) |
YOnehotify() |
__init__(self, num_classes) |
__call__(self, item) |
np.zeros((1, self.num_classes) |
Dataset() |
__init__(self, x, y, tfms_x, tfms_y) |
__len__(self) |
len(self.x) |
_get_transform(self, i, tfms) |
compose(i, tfms) |
__getitem__(self, i) |
isinstance(i, slice) |
self._get_transform(o, self.x_tfms) |
isinstance(i, slice) |
self._get_transform(o, self.y_tfms) |
np.vstack(return_x) |
np.vstack(return_y) |
DataLoader() |
__init__(self, ds, bs, drop_last=True) |
__iter__(self) |
len(self.ds) |
math.ceil(len(self.ds) |
range(0, length, 1) |
art.process_dataset(N = 1024 , FREQ = 'D', seed = 0, trendtype = "Lag1Trend", cycle_length = 30, transform = "RelativeDifference", sigma = 0.0, exog_count = 20, ar_order = 12) |
testmod.build_model( ['BoxCox'] , ['ConstantTrend'] , ['Seasonal_DayOfMonth'] , ['MLP'] ) |
np.vectorize(colorsys.rgb_to_hsv) |
np.vectorize(colorsys.hsv_to_rgb) |
crop(image, box=None) |
image.getbbox() |
image.crop(imageBox) |
hue_shift(image, value) |
image.convert('RGBA') |
np.array(np.asarray(im) |
astype(float) |
np.rollaxis(arr, axis=-1) |
print(np.max(r) |
rgb_to_hsv(r, g, b) |
hsv_to_rgb((h + value/360.0) |
np.dstack((r, g, b, a) |
print(np.max(r) |
plt.imshow(arr.astype(int) |
plt.show() |
Image.fromarray(arr.astype('uint8') |
argparse.ArgumentParser(description='Rainbow an image batch') |
parser.add_argument('--filename', dest='filename', type=str) |
parser.add_argument('--step', dest='step', type=float, default=5.0) |
parser.add_argument('--max_step', dest='max_step', type=float, default=360.0) |
parser.parse_args() |
Image.open(args.filename) |
os.path.basename(args.filename) |
os.path.splitext(basename) |
os.path.exists('anim') |
os.mkdir('anim') |
range(0, int(args.max_step/args.step) |
print('Writing out', dtheta) |
crop(color_image, (1620, 780, 2220, 1380) |
hue_shift(cropped, dtheta) |
os.path.join('anim','{0}_{1}{2}'.format(base, n, ext) |
new_im.save(new_fn) |
Tk() |
root.geometry("200x200") |
message() |
messagebox.showwarning("Alert Box", "Stop virus found") |
Button(root, text="ok", command=Message) |
but.place(x=100, y=100) |
root.mainloop() |
printLatestOutline(glaciers) |
glaciers.values() |
print("---") |
print(glacier) |
print(glacier.latestInventoryGeometry) |
configparser.ConfigParser() |
config.read("dataflow.cfg") |
Basodino (VAW-ID = 104) |
Aletsch (VAW-ID = 5) |
Corbassiere (VAW-ID = 38) |
GlacierReader(privateDatabaseAccessConfiguration) |
dict() |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.