100% satisfaction guarantee Immediately available after payment Both online and in PDF No strings attached
logo-home
NLP Quiz -4 Questions and Answers 2024 $12.99   Add to cart

Exam (elaborations)

NLP Quiz -4 Questions and Answers 2024

 1 view  0 purchase
  • Course
  • Institution

Exam of 3 pages for the course NLP at NLP (NLP Quiz -4)

Preview 1 out of 3  pages

  • October 31, 2024
  • 3
  • 2024/2025
  • Exam (elaborations)
  • Questions & answers
avatar-seller
NLP Quiz #4

when to use rematch and research – answer rematch () and research () are two
functions in Python's re module that are used to search for a pattern in a string. The
main difference between the two is that rematch () only matches the pattern at the
beginning of the string, while research () searches for the pattern anywhere in the string

differences between the regex quantifiers (? * + {}), and what |, $, and . mean - answer?
Matches the preceding character or group zero or one time.
*: Matches the preceding character or group zero or more times.
+: Matches the preceding character or group one or more times.
{n,m}: Matches the preceding character or group between n and m times.
. is a special character in regular expressions that matches any character except for a
newline character
| is another special character in regular expressions that is used to specify alternatives.
It matches either the expression before or after the |
$ is a special character in regular expressions that matches the end of a string

What's a word embedding? - answerA word embedding is a mapping of a word into a
vector space... words turn into numbers / vectors!

One-hot encoding - answerturning a feature/observation into a vector where exactly one
dimension has a non-zero value -- giving unique ID's to each word. for more categorical
data

For a vocabulary of size N, how big do the vectors need to be? - answerFor one-hot
encoding in a vocabulary of size N, each vector needs to be of size N.

Sparse vs Dense vectors - answerDense Vectors:
Representation: Dense vectors store all the elements of a vector, even if they are zero.
Storage: They use a fixed amount of memory equal to the size of the vector, regardless
of the actual number of non-zero elements.
Example: If you have a dense vector [2, 0, 0, 5], it would be stored as [2, 0, 0, 5] without
omitting any zeros.

Representation: Sparse vectors store only the non-zero elements along with their
indices.
Storage: They use memory proportional to the number of non-zero elements, which can
be much smaller than the size of the vector.
Example: The same vector [2, 0, 0, 5] would be represented sparsely as [(0, 2), (3, 5)],
indicating that the non-zero elements are at indices 0 and 3, with values 2 and 5,
respectively.

The benefits of buying summaries with Stuvia:

Guaranteed quality through customer reviews

Guaranteed quality through customer reviews

Stuvia customers have reviewed more than 700,000 summaries. This how you know that you are buying the best documents.

Quick and easy check-out

Quick and easy check-out

You can quickly pay through credit card or Stuvia-credit for the summaries. There is no membership needed.

Focus on what matters

Focus on what matters

Your fellow students write the study notes themselves, which is why the documents are always reliable and up-to-date. This ensures you quickly get to the core!

Frequently asked questions

What do I get when I buy this document?

You get a PDF, available immediately after your purchase. The purchased document is accessible anytime, anywhere and indefinitely through your profile.

Satisfaction guarantee: how does it work?

Our satisfaction guarantee ensures that you always find a study document that suits you well. You fill out a form, and our customer service team takes care of the rest.

Who am I buying these notes from?

Stuvia is a marketplace, so you are not buying this document from us, but from seller julianah420. Stuvia facilitates payment to the seller.

Will I be stuck with a subscription?

No, you only buy these notes for $12.99. You're not tied to anything after your purchase.

Can Stuvia be trusted?

4.6 stars on Google & Trustpilot (+1000 reviews)

84866 documents were sold in the last 30 days

Founded in 2010, the go-to place to buy study notes for 14 years now

Start selling
$12.99
  • (0)
  Add to cart