Original file line numberDiff line numberDiff line change @@ -0,0 +1,43 @@ from typing import List import torch import torch.nn as nn class MatryoshkaHead(nn.Module): """ https://github.com/RAIVNLab/MRL/blob/main/MRL.py Matryoshka linear layer for Matryoshka Representation Learning ""...
ifeq ("$(origin C)", "command line") KBUILD_CHECKSRC = $(C) endif ifndef KBUILD_CHECKSRC KBUILD_CHECKSRC = 0 endif # Use make M=dir to specify directory of external module to build # Old syntax make ... SUBDIRS=$PWD is still supported ...
Module): def __init__( self, layer_sizes, num_classes: int = 10, input_channels: int = 1, spline_order: int = 3, groups: int = 1): super(SimpleConvKAN, self).__init__() self.layers = nn.Sequential( KANConv2DLayer(input_channels, layer_sizes[0], spline_order, kernel_size=...
If the sqlite feature is enabled, this is downgraded to #![deny(unsafe_code)] with #![allow(unsafe_code)] on the sqlx::sqlite module. There are several places where we interact with the C SQLite API. We try to document each call for the invariants we're assuming. We absolutely welcom...
importtorchimporttorch.nnasnnfromkan_convsimportKANConv2DLayerclassSimpleConvKAN(nn.Module):def__init__(self,layer_sizes,num_classes:int=10,input_channels:int=1,spline_order:int=3,groups:int=1):super(SimpleConvKAN,self).__init__()self.layers=nn.Sequential(KANConv2DLayer(input_channels,laye...