broccoli-ml 13.0.0__tar.gz → 13.0.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: broccoli-ml
3
- Version: 13.0.0
3
+ Version: 13.0.1
4
4
  Summary: Some useful Pytorch models, circa 2025
5
5
  License: MIT
6
6
  Author: Nicholas Bailey
@@ -187,9 +187,14 @@ class ViTEncoder(nn.Module):
187
187
  transformer_stochastic_depth=0.1,
188
188
  transformer_checkpoint_ff=True,
189
189
  linear_module=nn.Linear,
190
+ alpha=1.0,
191
+ beta=1.0,
190
192
  ):
191
193
  super().__init__()
192
194
 
195
+ self.alpha = alpha
196
+ self.beta = beta
197
+
193
198
  if cnn_activation_kwargs is not None:
194
199
  self.cnn_activation = cnn_activation(**cnn_activation_kwargs)
195
200
  else:
@@ -491,6 +496,8 @@ class ViT(nn.Module):
491
496
  batch_norm_logits=True,
492
497
  logit_projection_layer=nn.Linear,
493
498
  linear_module=nn.Linear,
499
+ alpha=1.0,
500
+ beta=1.0,
494
501
  ):
495
502
 
496
503
  super().__init__()
@@ -511,6 +518,9 @@ class ViT(nn.Module):
511
518
  "SwiGLU": SwiGLU,
512
519
  }[transformer_activation]
513
520
 
521
+ self.alpha = alpha
522
+ self.beta = beta
523
+
514
524
  self.encoder = ViTEncoder(
515
525
  input_size=input_size,
516
526
  initial_batch_norm=initial_batch_norm,
@@ -559,6 +569,8 @@ class ViT(nn.Module):
559
569
  transformer_stochastic_depth=transformer_stochastic_depth,
560
570
  transformer_checkpoint_ff=transformer_checkpoint_ff,
561
571
  linear_module=linear_module,
572
+ alpha=alpha,
573
+ beta=beta,
562
574
  )
563
575
 
564
576
  self.pool = head(
@@ -1,6 +1,6 @@
1
1
  [project]
2
2
  name = "broccoli-ml"
3
- version = "13.0.0"
3
+ version = "13.0.1"
4
4
  description = "Some useful Pytorch models, circa 2025"
5
5
  authors = [
6
6
  {name = "Nicholas Bailey"}
File without changes
File without changes