0703344409780e55a055c03ff590c44d35cc10d0,thinc/layers/dropout.py,,,#,9

Before Change


// TODO: How to type the "sub-functions"?
// TODO: improve this and make array types more specific
InTArray = TypeVar("InTArray", bound=Array)
InputLengths = TypeVar("InputLengths", bound=Array)
InTList = List[InTArray]
InTRagged = Tuple[InTArray, InputLengths]
InT = Union[InTArray, InTList, InTRagged]
OutTArray = TypeVar("OutTArray", bound=Array)
OutputLengths = TypeVar("OutputLengths", bound=Array)
OutTList = List[OutTArray]
OutTRagged = Tuple[OutTArray, OutputLengths]
OutT = Union[OutTArray, OutTList, OutTRagged]


def Dropout(rate: float = 0.0) -> Model[InT, OutT]:

After Change




// TODO: improve this and make array types more specific?
InT = Union[Array, List[Array], Ragged]
OutT = Union[Array, List[Array], Ragged]

Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 6

Instances


Project Name: explosion/thinc
Commit Name: 0703344409780e55a055c03ff590c44d35cc10d0
Time: 2020-01-05
Author: ines@ines.io
File Name: thinc/layers/dropout.py
Class Name:
Method Name:


Project Name: explosion/thinc
Commit Name: 0703344409780e55a055c03ff590c44d35cc10d0
Time: 2020-01-05
Author: ines@ines.io
File Name: thinc/layers/foreach.py
Class Name:
Method Name:


Project Name: explosion/thinc
Commit Name: 10a385f5ae3c66d435f19580f009f563b12f30fb
Time: 2020-01-04
Author: honnibal+gh@gmail.com
File Name: thinc/layers/ragged2list.py
Class Name:
Method Name:


Project Name: explosion/thinc
Commit Name: 0703344409780e55a055c03ff590c44d35cc10d0
Time: 2020-01-05
Author: ines@ines.io
File Name: thinc/layers/dropout.py
Class Name:
Method Name: