cuda经纱rnn传感器的pytorch绑定

warp-rnnt的Python项目详细描述


CUDA经纱RNN传感器的Pythorch绑定

defrnnt_loss(log_probs,# type: torch.FloatTensorlabels,# type: torch.IntTensorframes_lengths,# type: torch.IntTensorlabels_lengths,# type: torch.IntTensoraverage_frames=False,# type: boolreduction=None,# type: Optional[AnyStr]blank=0,# type: int):"""The CUDA-Warp RNN-Transducer loss.    Args:      log_probs (torch.Tensor): Input tensor (float) with shape        (T, N, U, V) where T is the maximum number of input frames, N is the        minibatch size, U is the maximum number of output labels and V is        the vocabulary of labels (including the blank).      labels (torch.IntTensor): Tensor with shape (N, U-1) representing the        reference labels for all samples in the minibatch.      frames_lengths (torch.IntTensor): Tensor with shape (N,) representing the        number of frames for each sample in the minibatch.      labels_lengths (torch.IntTensor): Tensor with shape (N,) representing the        length of the transcription for each sample in the minibatch.      average_frames (bool, optional): Specifies whether the loss of each        sample should be divided by its number of frames. Default: ``False''.      reduction (string, optional): Specifies the type of reduction.        Default: None.      blank (int, optional): label used to represent the blank symbol.        Default: 0.    """# type: (...) -> torch.Tensor

要求

    C++ 11编译器(用GCC 5.4进行测试)。
  • python:3.5、3.6、3.7(用3.6版测试)。
  • PyTorch>;=1.0.0(使用版本1.1.0测试)。
  • CUDA Toolkit(使用10.0版测试)。

安装

目前,没有该包的编译版本。以下安装说明从本地源代码编译包。

来自Pypi

pip install warp_rnnt

来自github

git clone https://github.com/1ytic/warp-rnnt
cd warp-rnnt/pytorch_binding
python setup.py install

欢迎加入QQ群-->: 979659372 Python中文网_新手群

推荐PyPI第三方库


热门话题
java模拟存储库对象从controller testcase返回空结果?   Java扫描程序跳行异常   c#混淆If语句?   java为什么日志中的stacktrace前面没有这一行?   java如何使SSHJ在非标准端口上启动出站SFTP?   java我如何确定为什么每周收入没有在我的程序中显示前三次?   java如何判断堆叠条形图的轴的行为?   java rest json API的Web服务器体系结构   java ClassCastException:javax。摆动按扭   Java在Linux上不读取excel文件(使用Apache POI)   反馈错误后,java Wicket 1.4.9无法从modal使用AjaxRequestTarget!   java方法头中“静态”的含义是什么?   java无法在我的tomcat应用程序中添加外部库   java使用Itext Pdf将图像添加到Pdf文件   java为什么当我调用universe时java3d会闪烁。getCanvas()。getView()。重新油漆();   java Gson嵌套类在使用proguard时为空   java如何确定JSON路径对文档是否有效   java在使用Jsoup解析时保持HTML布尔属性的原始形式   使用Java SDK,如何在Azure存储文件服务中为文件设置元数据?