Best Python code snippet using Airtest
feed_forward_fpga.py
Source:feed_forward_fpga.py
1from neat.graphs import feed_forward_layers2from neat.six_util import itervalues3import numpy as np4#import serial5import time6from pynq import Overlay7import pynq.lib.dma8from pynq import MMIO9from pynq import Xlnk10from neat.activations import sigmoid_activation11#===pynq=============================================================12overlay = Overlay("/home/xilinx/pynq/overlays/systolic_hw/systolic_hw.bit")13dma = overlay.axi_dma_014mlp_axi = overlay.mlp_systolic_015IP_BASE = overlay.ip_dict['mlp_systolic_0']["phys_addr"]16#Define17STATE = 018COMMAND_VALID = 419COMMAND_ACK = 820COMMAND_IN_TOTAL = 1221COMMAND_OUT_TOTAL = 1622COMMAND_INIT_TOTAL_NODES = 2023COMMAND_INIT_IN_TOTAL = 2424COMMAND_DONE = 2825COMMAND_COMMAND_ACK = 3226COMMAND_COMMAND_INIT_ACK = 3627COMMAND_DONE_ACK = 4028COMMAND_RST_N = 4429#parameter30COLS = 1631xlnk = Xlnk()32class FeedForwardNetworkFPGA(object):33 def __init__(self, serial_in_pre, serial_in_post, in_num_nodes, out_num_nodes, quantize=8):34 self.serial_in_pre = serial_in_pre35 self.serial_in_post = serial_in_post36 self.in_num_nodes = in_num_nodes37 self.out_num_nodes = out_num_nodes38 self.quantize = quantize39 def activate_cpu(self, inputs):40 #time_s1 = time.time()41 if self.in_num_nodes != len(inputs):42 raise RuntimeError("Expected {0:n} inputs, got {1:n}".format(len(self.input_nodes), len(inputs)))43 quantize_1_time = 2**self.quantize44 quantize_2_time = 2 ** (2 * self.quantize)45 quantize_3_time = 2**(3*self.quantize)46 serial_in = np.int_(self.serial_in_pre + [int(n * quantize_1_time) for n in inputs] + self.serial_in_post)47 # for i in range(len(serial_in)):48 # data = serial_in[i]49 # fp.write('{}\n'.format(data))50 # fp.close()51 o_id = 052 base_addr = 053 command_layer = serial_in[base_addr] - 154 base_addr += 155 command_init_total_node = serial_in[base_addr]56 base_addr += 157 command_init_in_nodes = serial_in[base_addr]58 base_addr += 159 in_total_s = [0 for i in range(command_layer)]60 out_total_s = [0 for i in range(command_layer)]61 #====NON-LINEAR=====62 #===relu====aa63 #relu_max_par = 16 * quantize_3_time64 #relu_min_par = 065 #===le_relu======66 #le_relu_par = (2 / quantize_1_time)67 #=======================68 for i in range(command_layer):69 in_total_s[i] = serial_in[base_addr]70 base_addr += 171 out_total_s[i] = serial_in[base_addr]72 base_addr += 173 resp_s = serial_in[base_addr:base_addr+command_init_total_node]74 base_addr += command_init_total_node75 bias_s = serial_in[base_addr:base_addr+command_init_total_node]76 base_addr += command_init_total_node77 V_s = np.zeros((command_init_total_node, 1)).astype(int)78 V_s[0:command_init_in_nodes] = serial_in[base_addr:base_addr+command_init_in_nodes].reshape((-1,1))79 base_addr += command_init_in_nodes80 #time_e = 081 for layer_idx in range(command_layer):82 out_total, in_total = out_total_s[layer_idx], in_total_s[layer_idx]83 o_id = serial_in[base_addr:base_addr+out_total]84 base_addr += out_total85 i_id = serial_in[base_addr:base_addr+in_total]86 base_addr += in_total87 W_serial = serial_in[base_addr:base_addr+out_total*in_total]88 base_addr += out_total*in_total89 W = W_serial.reshape(out_total, in_total)90 I = V_s[i_id]91 resp = resp_s[o_id].reshape(out_total, -1)92 bias = bias_s[o_id].reshape(out_total, -1)93 #time_s = time.time()94 O = np.matmul(W, I)95 V = (resp * O + bias)96 #====No activation===97 #V_s[o_id] = V98 #==================99 #====relu====100 #V_s[o_id] = np.maximum(np.minimum(V, relu_max_par), relu_min_par) / quantize_2_time101 #V_s[o_id] = V102 V_s[o_id] = np.maximum(V, 0) / quantize_2_time103 #time_e += time.time() - time_s104 #===le_relu======105 #V_s[o_id] = np.int_(np.maximum(np.minimum(V, relu_max_par), V * le_relu_par) / quantize_2_time)106 ret = [float(v/quantize_1_time) for v in V_s[o_id]]107 #time_e = 1000 * (time_e)108 #time_all = 1000 * (time.time() - time_s1)109 #print("Calculation time ", time_e, "msec")110 #print("Data processing time ", time_all-time_e, "msec")111 if command_layer == 0:112 return inputs113 return ret114 def activate_fpga(self, inputs):115 #time_s1 = time.time()116 mlp_axi.write(COMMAND_RST_N, 0)117 mlp_axi.write(COMMAND_RST_N, 1)118 if self.in_num_nodes != len(inputs):119 raise RuntimeError("Expected {0:n} inputs, got {1:n}".format(len(self.input_nodes), len(inputs)))120 quantize_1_time = 2**self.quantize121 quantize_2_time = 2 ** (2 * self.quantize)122 quantize_3_time = 2**(3*self.quantize)123 serial_in = np.int_(self.serial_in_pre + [int(n * quantize_1_time) for n in inputs] + self.serial_in_post)124 o_id = 0125 base_addr = 0126 command_layer = serial_in[base_addr] - 1127 base_addr += 1128 command_init_total_node = serial_in[base_addr]129 base_addr += 1130 command_init_in_nodes = serial_in[base_addr]131 base_addr += 1132 in_total_s = [0 for i in range(command_layer)]133 out_total_s = [0 for i in range(command_layer)]134 if command_layer != 0:135 #====NON-LINEAR=====136 #===relu====aa137 #relu_max_par = 16 * quantize_3_time138 #relu_min_par = 0139 #===le_relu======140 #le_relu_par = (2 / quantize_1_time)141 #=======================142 for i in range(command_layer):143 in_total_s[i] = serial_in[base_addr]144 base_addr += 1145 out_total_s[i] = serial_in[base_addr]146 base_addr += 1147 mlp_axi.write(COMMAND_COMMAND_INIT_ACK, 0)148 mlp_axi.write(COMMAND_COMMAND_ACK, 0)149 mlp_axi.write(COMMAND_DONE_ACK, 0)150 mlp_axi.write(COMMAND_DONE, 0)151 while (mlp_axi.read(COMMAND_VALID)):152 mlp_axi.write(COMMAND_INIT_TOTAL_NODES, int(command_init_total_node))153 mlp_axi.write(COMMAND_INIT_IN_TOTAL, int(command_init_in_nodes))154 mlp_axi.write(COMMAND_COMMAND_INIT_ACK, 1)155 #print("1. waiting in state", mlp_axi.read(STATE))156 mlp_axi.write(COMMAND_COMMAND_INIT_ACK, 0)157 mlp_axi.write(COMMAND_COMMAND_ACK, 0)158 dma_in_buffer_size = command_init_total_node * 2 + command_init_in_nodes;159 dma_out_buffer_size = 0;160 resp_s = serial_in[base_addr:base_addr+command_init_total_node]161 base_addr += command_init_total_node162 bias_s = serial_in[base_addr:base_addr+command_init_total_node]163 base_addr += command_init_total_node164 V_s = serial_in[base_addr:base_addr+command_init_in_nodes]165 base_addr += command_init_in_nodes166 dma_in_buf = xlnk.cma_array(shape=(dma_in_buffer_size,1), dtype=np.int32)167 dma_in_buf[:] = np.concatenate((resp_s, bias_s, V_s)).reshape(-1,1)168 dma.sendchannel.transfer(dma_in_buf)169 dma.sendchannel.wait()170 while(mlp_axi.read(STATE)==2):171 print("2. waiting in state %d", mlp_axi.read(STATE))172 del dma_in_buf173 #time_e = 0174 175 for layer_idx in range(command_layer):176 out_total, in_total = out_total_s[layer_idx], in_total_s[layer_idx]177 while (mlp_axi.read(COMMAND_VALID)):178 mlp_axi.write(COMMAND_IN_TOTAL, int(in_total))179 mlp_axi.write(COMMAND_OUT_TOTAL, int(out_total))180 mlp_axi.write(COMMAND_COMMAND_ACK, 1)181 mlp_axi.write(COMMAND_COMMAND_ACK, 0)182 o_id = serial_in[base_addr:base_addr+out_total]183 base_addr += out_total184 i_id = serial_in[base_addr:base_addr+in_total]185 base_addr += in_total186 W_serial = serial_in[base_addr:base_addr+out_total*in_total]187 base_addr += out_total*in_total188 dma_in_buffer_size = out_total + in_total +out_total*in_total189 dma_in_buf = xlnk.cma_array(shape=(dma_in_buffer_size,1), dtype=np.int32)190 dma_in_buf[:] = np.concatenate((o_id, i_id, W_serial)).reshape(-1,1)191 dma.sendchannel.transfer(dma_in_buf)192 dma.sendchannel.wait()193 del dma_in_buf194 while(mlp_axi.read(STATE)<7):195 print("3. waiting in state", mlp_axi.read(STATE))196 if layer_idx == command_layer - 1:197 dma_out_buffer_size = out_total_s[-1]198 #dma_out_buffer_size = 2 * (in_total_s[0] + out_total_s[0]) + COLS * in_total_s[0]199 dma_out_buf = xlnk.cma_array(shape=(dma_out_buffer_size,1), dtype=np.int32)200 dma.recvchannel.transfer(dma_out_buf)201 while (mlp_axi.read(STATE)==8):202 mlp_axi.write(COMMAND_DONE, 1)203 mlp_axi.write(COMMAND_DONE_ACK, 1)204 if(mlp_axi.read(STATE)==9):205 dma.recvchannel.wait()206 else:207 while (mlp_axi.read(STATE)==8):208 mlp_axi.write(COMMAND_DONE, 0)209 mlp_axi.write(COMMAND_DONE_ACK, 1)210 mlp_axi.write(COMMAND_DONE, 0)211 mlp_axi.write(COMMAND_DONE_ACK, 0) 212 try:213 ret = [float(v/quantize_1_time) for v in dma_out_buf]214 del dma_out_buf215 except:216 print("command_layer", command_layer)217 return ret218 else:219 return inputs220 def activate(self, inputs):221 if self.in_num_nodes != len(inputs):222 raise RuntimeError("Expected {0:n} inputs, got {1:n}".format(len(self.input_nodes), len(inputs)))223 quantize_1_time = 2 ** self.quantize224 quantize_2_time = 2 ** (2 * self.quantize)225 quantize_3_time = 2 ** (3 * self.quantize)226 serial_in = np.int_(self.serial_in_pre + [int(n * quantize_1_time) for n in inputs] + self.serial_in_post)227 num_of_layer = serial_in[0]228 # if num_of_layer == 1 or self.out_num_nodes == 0:229 # return [0]230 # if (serial_in[0] == 4 and serial_in[1] == 8) or (serial_in[0] == 3 and serial_in[1] == 4):231 # return [0]232 # print("I: ",self.serial_in_pre)233 # print(inputs)234 # print("W: ", self.serial_in_post)235 ser = serial.Serial(236 port='/dev/tty.usbmodem14111',237 baudrate=115200,238 parity=serial.PARITY_NONE,239 stopbits=serial.STOPBITS_ONE,240 bytesize=serial.EIGHTBITS241 )242 if ser.isOpen():243 ser.close()244 ser.open()245 ser.isOpen()246 ####To send ITER_IN_VIVADO through uart===247 temp = int(len(serial_in)) & 0xffffffff248 ser.write(temp.to_bytes(length=4, byteorder='big'))249 ##=======================================250 for i in range(0, len(serial_in)):251 temp = int(serial_in[i]) & 0xffffffff252 ser.write(temp.to_bytes(length=4, byteorder='big'))253 result_serial = []254 for i in range(self.out_num_nodes+1):255 data = ser.readline()256 # print("i: ",i, "data: ", bytes.decode(data))257 try:258 temp = int(data)259 except:260 #print("My error: data =", data)261 continue262 result_serial.append(float(temp/(quantize_1_time)))263 #print(result_serial)264 return result_serial265 @staticmethod266 def create(genome, config, quantize = 8):267 """ Receives a genome and returns its phenotype (a FeedForwardNetwork). """268 idx = 0269 valueIDMap_neat2fpga = dict()270 valueIDMap_fpga2neat = dict()271 for o_id in config.genome_config.input_keys + config.genome_config.output_keys:272 valueIDMap_neat2fpga[o_id] = idx273 valueIDMap_fpga2neat[idx] = o_id274 idx += 1275 # Gather expressed connections.276 connections = [cg.key for cg in itervalues(genome.connections) if cg.enabled]277 layers = feed_forward_layers(config.genome_config.input_keys, config.genome_config.output_keys, connections)278 layer = []279 for c in connections:280 for i in range(2):281 if c[i] not in valueIDMap_neat2fpga:282 o_id = c[i]283 valueIDMap_neat2fpga[o_id] = idx284 valueIDMap_fpga2neat[idx] = o_id285 idx += 1286 total_nodes = idx287 command_layer = len(layers) + 1288 command_init_total_node = len(valueIDMap_neat2fpga)289 command_init_in_nodes = len(config.genome_config.input_keys)290 command_s = [command_layer, command_init_total_node, command_init_in_nodes]291 resp_s = [0] * total_nodes292 bias_s = [0] * total_nodes293 for idx in range(command_init_in_nodes,total_nodes, 1):294 o_id = valueIDMap_fpga2neat[idx]295 ng = genome.nodes[o_id]296 resp_s[idx] = int(ng.response * 2**quantize)297 bias_s[idx] = int(ng.bias * 2**(quantize + quantize + quantize))298 serial_in_pre = command_s299 serial_in_post = []300 for idx,layer in enumerate(layers):301 inputVectorThisLayer = []302 i_id = []303 outputVectorThisLayer = []304 o_id = []305 key_weight_dict = dict()306 for node in layer:307 for conn_key in connections:308 inode, onode = conn_key309 if onode == node:310 if inode not in inputVectorThisLayer:311 inputVectorThisLayer.append(inode)312 i_id.append(valueIDMap_neat2fpga[inode])313 if onode not in outputVectorThisLayer:314 outputVectorThisLayer.append(onode)315 o_id.append(valueIDMap_neat2fpga[onode])316 indx_i = inputVectorThisLayer.index(inode)317 indx_o = outputVectorThisLayer.index(onode)318 cg = genome.connections[conn_key]319 key_weight_dict.update({(indx_i, indx_o): cg.weight})320 weight_matrix = np.zeros((len(outputVectorThisLayer), len(inputVectorThisLayer)))321 for key, val in key_weight_dict.items():322 indx_i, indx_o = key323 weight_matrix[indx_o][indx_i] =int(val * 2**quantize)324 # if idx ==0:325 # print("init_in_total: ", command_init_in_nodes, "in_first :", len(inputVectorThisLayer))326 serial_in_pre.append(len(inputVectorThisLayer))327 serial_in_pre.append(len(outputVectorThisLayer))328 serial_in_post = serial_in_post + o_id + i_id + list(np.ravel(weight_matrix))329 serial_in_pre = serial_in_pre + resp_s + bias_s330 return FeedForwardNetworkFPGA(serial_in_pre, serial_in_post, command_init_in_nodes, len(layer), quantize)331if __name__ == '__main__':332 serial_in_pre = [2, 4, 2, 2, 1, 3, 1, 0, 0, 256, 256, 0, 0, -8338623, -217866857]333 serial_in_post =[3,0,1, -888, 571,2,3,1,0,682,-247,326]334 in_num_nodes = 2335 out_num_nodes = 1336 quantize = 8337 inputs = [1,0]338 fpga_net = FeedForwardNetworkFPGA(serial_in_pre, serial_in_post, in_num_nodes, out_num_nodes, quantize=8)...
feed_forward_fpga2.py
Source:feed_forward_fpga2.py
1from neat.graphs import feed_forward_layers2from neat.six_util import itervalues3import numpy as np4import serial5import time6from neat.activations import sigmoid_activation7class FeedForwardNetworkFPGA(object):8 def __init__(self, serial_in_pre, serial_in_post, in_num_nodes, out_num_nodes, quantize=12):9 self.serial_in_pre = np.int32(serial_in_pre)10 self.serial_in_post = np.int32(serial_in_post)11 self.in_num_nodes = in_num_nodes12 self.out_num_nodes = out_num_nodes13 self.quantize = quantize14 def activate_cpu(self, inputs):15 #time_s1 = time.time()16 if self.in_num_nodes != len(inputs):17 raise RuntimeError("Expected {0:n} inputs, got {1:n}".format(len(self.input_nodes), len(inputs)))18 quantize_1_time = 2**self.quantize19 quantize_2_time = 2 ** (2 * self.quantize)20 quantize_3_time = 2**(3*self.quantize)21 inputs = np.int32(inputs)22 inputs *= quantize_1_time23 serial_in = np.concatenate((self.serial_in_pre, inputs, self.serial_in_post), axis=None)24 o_id = 025 base_addr = 026 command_layer = serial_in[base_addr]27 base_addr += 128 command_init_total_node = serial_in[base_addr]29 base_addr += 130 command_init_in_nodes = serial_in[base_addr]31 base_addr += 132 in_total_s = [0 for i in range(command_layer)]33 out_total_s = [0 for i in range(command_layer)]34 #====NON-LINEAR=====35 #===relu====aa36 relu_max_par = 256 * quantize_1_time37 relu_min_par = 038 #===le_relu======39 #le_relu_par = (2 / quantize_1_time)40 #=======================41 for i in range(command_layer):42 in_total_s[i] = serial_in[base_addr]43 base_addr += 144 out_total_s[i] = serial_in[base_addr]45 base_addr += 146 resp_s = serial_in[base_addr:base_addr+command_init_total_node]47 base_addr += command_init_total_node48 bias_s = serial_in[base_addr:base_addr+command_init_total_node]49 base_addr += command_init_total_node50 V_s = np.zeros((command_init_total_node, 1)).astype(np.int32)51 V_s[0:command_init_in_nodes] = serial_in[base_addr:base_addr+command_init_in_nodes].reshape((-1,1))52 base_addr += command_init_in_nodes53 #time_e = 054 for layer_idx in range(command_layer):55 out_total, in_total = out_total_s[layer_idx], in_total_s[layer_idx]56 o_id = serial_in[base_addr:base_addr+out_total]57 base_addr += out_total58 i_id = serial_in[base_addr:base_addr+in_total]59 base_addr += in_total60 W_serial = serial_in[base_addr:base_addr+out_total*in_total]61 base_addr += out_total*in_total62 W = W_serial.reshape(out_total, in_total)63 I = V_s[i_id]64 resp = resp_s[o_id].reshape(out_total, -1)65 bias = bias_s[o_id].reshape(out_total, -1)66 #time_s = time.time()67 O = np.matmul(W, I) // quantize_1_time68 V = (resp * O // quantize_1_time + bias)69 #====No activation===70 #V_s[o_id] = V71 #==================72 #====relu====73 V_s[o_id] = np.maximum(np.minimum(V, relu_max_par), relu_min_par)74 #time_e += time.time() - time_s75 #===le_relu======76 #V_s[o_id] = np.int_(np.maximum(np.minimum(V, relu_max_par), V * le_relu_par) / quantize_2_time)77 ret = [float(v/quantize_1_time) for v in V_s[o_id]]78 #time_e = 1000 * (time_e)79 #time_all = 1000 * (time.time() - time_s1)80 #print("Calculation time ", time_e, "msec")81 #print("Data processing time ", time_all-time_e, "msec")82 return ret83 def activate(self, inputs):84 if self.in_num_nodes != len(inputs):85 raise RuntimeError("Expected {0:n} inputs, got {1:n}".format(len(self.input_nodes), len(inputs)))86 quantize_1_time = 2 ** self.quantize87 quantize_2_time = 2 ** (2 * self.quantize)88 quantize_3_time = 2 ** (3 * self.quantize)89 serial_in = self.serial_in_pre + [int(n* quantize_1_time) for n in inputs] + self.serial_in_post90 ser = serial.Serial(91 port='/dev/tty.usbmodem14431',92 baudrate=115200,93 parity=serial.PARITY_NONE,94 stopbits=serial.STOPBITS_ONE,95 bytesize=serial.EIGHTBITS96 )97 if ser.isOpen():98 ser.close()99 ser.open()100 ser.isOpen()101 ####To send ITER_IN_VIVADO through uart===102 temp = int(len(serial_in)) & 0xffffffff103 ser.write(temp.to_bytes(length=4, byteorder='big'))104 ##=======================================105 for i in range(0, len(serial_in)):106 temp = int(serial_in[i]) & 0xffffffff107 ser.write(temp.to_bytes(length=4, byteorder='big'))108 result_serial = []109 for i in range(self.out_num_nodes):110 data = ser.readline()111 # print("i: ",i, "data: ", bytes.decode(data))112 try:113 temp = int(data)114 except:115 print("My error: data =", data)116 continue117 result_serial.append(float(temp/(quantize_1_time)))118 return result_serial119 @staticmethod120 def create(genome, config, quantize = 12):121 """ Receives a genome and returns its phenotype (a FeedForwardNetwork). """122 idx = 0123 valueIDMap_neat2fpga = dict()124 valueIDMap_fpga2neat = dict()125 for o_id in config.genome_config.input_keys + config.genome_config.output_keys:126 valueIDMap_neat2fpga[o_id] = idx127 valueIDMap_fpga2neat[idx] = o_id128 idx += 1129 # Gather expressed connections.130 connections = [cg.key for cg in itervalues(genome.connections) if cg.enabled]131 layers = feed_forward_layers(config.genome_config.input_keys, config.genome_config.output_keys, connections)132 layer = []133 for c in connections:134 for i in range(2):135 if c[i] not in valueIDMap_neat2fpga:136 o_id = c[i]137 valueIDMap_neat2fpga[o_id] = idx138 valueIDMap_fpga2neat[idx] = o_id139 idx += 1140 total_nodes = idx141 command_layer = len(layers)142 command_init_total_node = len(valueIDMap_neat2fpga)143 command_init_in_nodes = len(config.genome_config.input_keys)144 command_s = [command_layer, command_init_total_node, command_init_in_nodes]145 resp_s = [0] * total_nodes146 bias_s = [0] * total_nodes147 for idx in range(command_init_in_nodes,total_nodes, 1):148 o_id = valueIDMap_fpga2neat[idx]149 ng = genome.nodes[o_id]150 resp_s[idx] = int(ng.response * 2**quantize)151 bias_s[idx] = int(ng.bias * 2**(quantize))152 serial_in_pre = command_s153 serial_in_post = []154 for layer in layers:155 inputVectorThisLayer = []156 i_id = []157 outputVectorThisLayer = []158 o_id = []159 key_weight_dict = dict()160 for node in layer:161 for conn_key in connections:162 inode, onode = conn_key163 if onode == node:164 if inode not in inputVectorThisLayer:165 inputVectorThisLayer.append(inode)166 i_id.append(valueIDMap_neat2fpga[inode])167 if onode not in outputVectorThisLayer:168 outputVectorThisLayer.append(onode)169 o_id.append(valueIDMap_neat2fpga[onode])170 indx_i = inputVectorThisLayer.index(inode)171 indx_o = outputVectorThisLayer.index(onode)172 cg = genome.connections[conn_key]173 key_weight_dict.update({(indx_i, indx_o): cg.weight})174 weight_matrix = np.zeros((len(outputVectorThisLayer), len(inputVectorThisLayer)))175 for key, val in key_weight_dict.items():176 indx_i, indx_o = key177 weight_matrix[indx_o][indx_i] =int(val * 2**quantize)178 serial_in_pre.append(len(inputVectorThisLayer))179 serial_in_pre.append(len(outputVectorThisLayer))180 serial_in_post = serial_in_post + o_id + i_id + list(np.ravel(weight_matrix))181 serial_in_pre = serial_in_pre + resp_s + bias_s182 return FeedForwardNetworkFPGA(serial_in_pre, serial_in_post, command_init_in_nodes, len(layer), quantize)183if __name__ == '__main__':184 serial_in_pre = [2, 4, 2, 2, 1, 3, 1, 0, 0, 256, 256, 0, 0, -10, -20]185 serial_in_post =[3,0,1, -888, 571,2,3,1,0,682,-247,326]186 in_num_nodes = 2187 out_num_nodes = 1188 quantize = 8189 inputs = [1,0]190 fpga_net = FeedForwardNetworkFPGA(serial_in_pre, serial_in_post, in_num_nodes, out_num_nodes, quantize=8)...
Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.
You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.
Get 100 minutes of automation test minutes FREE!!