Skip to content
This repository was archived by the owner on Sep 9, 2026. It is now read-only.
This repository was archived by the owner on Sep 9, 2026. It is now read-only.

update not working when NdArray as attribute #1627

Closed

Description

@JoanFM

Initial Checks

  • I have read and followed the docs and still think this is a bug

Description

update method fails to update a Document with NdArray

Example Code

from docarray import DocList, BaseDoc

from docarray.typing import NdArray

import random
import string

import numpy as np

class MyDoc(BaseDoc):
    text: str
    embedding: NdArray[128]

MyDoc(id='0', text='', embedding=np.random.rand(128)).update(MyDoc(id='0', text='', embedding=np.random.rand(128)))

Python, Pydantic & OS Version

0.33.0

Affected Components

Activity

  1. changed the title [-]reduce_all not working when NdArray as attribute[/-] [+]`update` not working when NdArray as attribute[/+] on Jun 6, 2023
  2. self-assigned this
    on Jun 6, 2023
  3. moved this to Todo/Bug in DocArray backlogon Jun 6, 2023
  4. linked a pull request that will close this issuefix: fix update with tensors #1628on Jun 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions