by Suf | Dec 1, 2021 | Data Science, Programming, Python, Tips
Table of contentsWhat is a String?What is a Substring in Python?Using split()Using [start:]Using [:end]Using [start:end:step]Using List ComprehensionCheck if Substring Exists in SubstringSimilarities Between StringsPython String ComparisonSummary What is a String? A...
by Suf | Nov 30, 2021 | Data Science, Programming, Python, Tips
If we try to concatenate an integer with a string, we will raise the error “TypeError: can only concatenate str (not “int”) to str”. This error occurs because you can only concatenate strings with other strings. In this tutorial, we will go through the...
by Suf | Nov 27, 2021 | Programming, Python, Tips
Python is a popular programming language, widely used for data science and machine learning. The language comes with a wide range of libraries and packages, which have their versions and may require a specific version of Python. This article describes how to check and...
by Suf | Nov 27, 2021 | Data Science, Programming, Python, Tips
Table of contentsWhat is Cosine Similarity?How to Calculate Cosine SimilarityCosine DistanceVisual Description of Cosine SimilarityNumerical Example of Cosine SimilarityPython Example of Cosine SimilarityDifferences Between Cosine and Jaccard SimilaritySoft Cosine...
by Suf | Nov 25, 2021 | Data Science, Programming, Python, Tips
Understanding the similarity between two objects is a universal problem. In machine learning, you can use similarity measures for various issues. These include object detection, classification and segmentation tasks in computer vision and similarity between text...