# BCEloss log base

**URL:** <https://discuss.pytorch.org/t/bceloss-log-base/36833>\
**Category:** Uncategorized\
**Created:** [February 10, 2019, 5:20pm UTC](https://discuss.pytorch.org/t/bceloss-log-base/36833 "2019-02-10T17:20:31Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![dimchasani](https://discuss.pytorch.org/user_avatar/discuss.pytorch.org/dimchasani/32/7933_2.png) [@dimchasani](https://discuss.pytorch.org/u/dimchasani)\
**Post date:** [February 10, 2019, 5:20pm UTC](https://discuss.pytorch.org/t/bceloss-log-base/36833/1 "2019-02-10T17:20:31Z")

</div>

So my question is, what is the log base BCEloss uses? I read the docs, but couldn’t find anything.

---

<div class="post-metadata">

**Author:** ![ptrblck](https://discuss.pytorch.org/user_avatar/discuss.pytorch.org/ptrblck/32/1823_2.png) [@ptrblck](https://discuss.pytorch.org/u/ptrblck)\
**Post date:** [February 10, 2019, 5:27pm UTC](https://discuss.pytorch.org/t/bceloss-log-base/36833/2 "2019-02-10T17:27:58Z")

</div>

`torch.log` uses the natural logarithm, i.e. base `e`:

```python
torch.log(torch.tensor(np.e))
> tensor(1.)

```
