Skip to content

Commit

Permalink
update Adapter class
Browse files Browse the repository at this point in the history
  • Loading branch information
julian-fong committed Oct 23, 2024
1 parent 0660776 commit ca9905b
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/adapters/methods/modeling.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

from ..configuration import AdapterFusionConfig, BnConfig
from ..context import ForwardContext
from vision import StochasticDepth
from .vision import StochasticDepth


class Activation_Function_Class(nn.Module):
Expand Down Expand Up @@ -144,8 +144,8 @@ def __init__(
else:
raise ValueError("Unknown init_weights type: {}".format(config["init_weights"]))

if config["drop_path"] > 0.0:
self.DropPath = StochasticDepth(drop_prob=config["drop_path"])
if config["stochastic_depth"] > 0.0:
self.DropPath = StochasticDepth(drop_prob=config["stochastic_depth"])

def pre_forward(
self,
Expand Down

0 comments on commit ca9905b

Please sign in to comment.