Skip to content

docs: adjust readme according to suggestions#577

Merged
JoanFM merged 6 commits intomainfrom
fix-example-4-readme
Sep 30, 2022
Merged

docs: adjust readme according to suggestions#577
JoanFM merged 6 commits intomainfrom
fix-example-4-readme

Conversation

@JoanFM
Copy link
Copy Markdown
Member

@JoanFM JoanFM commented Sep 28, 2022

Goals:

Adjust to suggestions to help people follow readme in an easier way

@codecov
Copy link
Copy Markdown

codecov bot commented Sep 28, 2022

Codecov Report

Merging #577 (e6cb3b0) into main (521864c) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #577   +/-   ##
=======================================
  Coverage   86.40%   86.40%           
=======================================
  Files         134      134           
  Lines        6714     6714           
=======================================
  Hits         5801     5801           
  Misses        913      913           
Flag Coverage Δ
docarray 86.40% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

Copy link
Copy Markdown
Contributor

@NicholasDunham NicholasDunham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A couple of minor grammatical changes. Separate from those, I'm not sure about the "If you have XGB of RAM" part—is a specific amount of RAM required, or do we just want to say "If you have a lot of RAM"?

@BenjaminEliaMueller
Copy link
Copy Markdown

With the X amount of RAM I meant an approximate minimum of usable RAM that you need to have, in order to execute the readme example with the full dataset. I cannot test the actual RAM usage of a run with the full dataset myself since I have only 16G available.

When trying out the example at todays Hackathon (at Jina in Berlin) everyone who tested the examples was running into this issue.

@JoanFM
Copy link
Copy Markdown
Member Author

JoanFM commented Sep 29, 2022

With the X amount of RAM I meant an approximate minimum of usable RAM that you need to have, in order to execute the readme example with the full dataset. I cannot test the actual RAM usage of a run with the full dataset myself since I have only 16G available.

When trying out the example at todays Hackathon (at Jina in Berlin) everyone who tested the examples was running into this issue.

yes X amount is a placeholder, I have to compute this. I have tried now and I could not manage to have it working without crashing and I have 16 GB RAM.

How much memory u need to run this?

from docarray import DocumentArray

left_da = DocumentArray.pull('demo-leftda', show_progress=False)

from docarray import Document


def preproc(d: Document):
    return (
        d.load_uri_to_image_tensor()  # load
            .set_image_tensor_normalization()  # normalize color
            .set_image_tensor_channel_axis(-1, 0)
    )  # switch color axis for the PyTorch model later


left_da.apply(preproc)

import torchvision

model = torchvision.models.resnet50(pretrained=True)  # load ResNet50
left_da.embed(model, device='cpu')

right_da = (
    DocumentArray.pull('demo-rightda', show_progress=True)
        .apply(preproc)
        .embed(model, device='cpu')
)

left_da.match(right_da, limit=9)

@JoanFM JoanFM closed this Sep 29, 2022
@JoanFM JoanFM reopened this Sep 29, 2022
@JoanFM JoanFM closed this Sep 29, 2022
@JoanFM JoanFM reopened this Sep 29, 2022
@github-actions
Copy link
Copy Markdown

📝 Docs are deployed on https://ft-fix-example-4-readme--jina-docs.netlify.app 🎉

@JoanFM JoanFM linked an issue Sep 29, 2022 that may be closed by this pull request
@JoanFM JoanFM marked this pull request as ready for review September 29, 2022 20:17
Copy link
Copy Markdown
Contributor

@NicholasDunham NicholasDunham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One more wording change. Other than that, looks good.

Co-authored-by: Nicholas Dunham <[email protected]>
Copy link
Copy Markdown
Contributor

@NicholasDunham NicholasDunham left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@JoanFM JoanFM merged commit 57073c0 into main Sep 30, 2022
@JoanFM JoanFM deleted the fix-example-4-readme branch September 30, 2022 07:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Readme Example 4: Suggestions

3 participants