Skip to content

flow.div 算子和 torch.div 没对齐 #242

Description

@triple-mu

image

import oneflow as flow
import torch
import numpy as np

a = np.random.randn(3,3).astype(np.float32)

b = 2

torch_a = torch.from_numpy(a)
flow_a = flow.from_numpy(a)

print(torch.div(torch_a,b,rounding_mode='floor'))
print(flow.div(flow_a,b).floor())
print(flow.div(flow_a,b,rounding_mode='floor'))

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions