Saturday 28 September 2024

Mac: "Recovery server could not be contacted"

After reseting a Mac to factory settings, one might need to deal with the following error: "Recovery server could not be contacted"

To fix the error, when entering the recovery mode, try holding cmd + option + r instead of cmd + r.

Friday 7 June 2024

Mixed Content error

I would like to share a very tricky error one might encounter. I use React for my frontend and Flask for my backend. I run my website through HTTPS and receive the following error in the browser console:


Mixed Content: The page at 'https://[domain_name]/' was loaded over HTTPS, but requested an insecure resource 'http:// [domain_name]/api/'. This request has been blocked; the content must be served over HTTPS.


The page https://[domain_name]/api/ worked perfectly fine in the browser. One might think that the problem is in how the requests are redirected (for example in the NGINX configuration file). But the problem turned out to be in the Flask routing. I used @app.route("/api/", methods=["GET"]) instead of @app.route("/api", methods=["GET"]).

 

Tuesday 10 January 2023

Serendipity in Recommender Systems: updates of 2023

Recommender systems are ubiquitous. Netflix recommends movies and tv series to users. Spotify recommends audio tracks. Facebook recommends friends. Although these recommendations are often precise, they are also often boring. For example, these systems often suggest items, such as movies or audio recordings that users are already familiar with or would find anyway by themselves. To mitigate this problem, researchers started optimising recommender systems not only for accuracy (items that users like), but also for serendipity. There is no consensus on the definition of the term serendipity in recommender systems (RecSys), but most often researchers consider an item serendipitous if it is relevant, novel and unexpected to the user. Relevance indicates that the user is interested in the item, novelty - the user had been unaware of the item prior to consuming it, while unexpectedness has a number of definitions with the most common being that the item is dissimilar to what the user usually consumes.

Friday 14 January 2022

Difference between interpreting linear and logistic regression coefficients

Linear regression

Let's assume, we have the following linear regression model:

Then,  the difference between two outcomes is going to be as follows:

Let's assume that x has one-unit increase, but z stays unchanged:

The difference is then as follows:
We can say that one-unit increase in x, when other parameters held constant, results in b1 increase in y.

Saturday 8 May 2021

Paper: Revisiting the Tag Relevance Prediction Problem

 Paper link: https://www.researchgate.net/publication/351347450_Revisiting_the_Tag_Relevance_Prediction_Problem

GitHub: https://github.com/Bionic1251/Revisiting-the-Tag-Relevance-Prediction-Problem

Traditionally, recommender systems provide a list of suggestions to a user based on past interactions with items of this user. These recommendations are usually based on user preferences for items and generated with a delay. Critiquing recommender systems allow users to provide immediate feedback to recommendations with tags and receive a new set of recommendations in response. However, these systems often require rich item descriptions that contain relevance scores indicating the strength, with which a tag applies to an item. For example, this relevance score could indicate how violent the movie ``The Godfather'' is on a scale from 0 to 1. Retrieving these data is a very demanding process, as it requires users to explicitly indicate the degree to which a tag applies to an item. This process can be improved with machine learning methods that predict tag relevance. In this paper, we explore the dataset from a different study, where the authors collected relevance scores on movie-tag pairs. In particular, we define the tag relevance prediction problem, explore the inconsistency of relevance scores provided by users as a challenge of this problem and present a method, which outperforms the state-of-the-art method for predicting tag relevance. We found a moderate inconsistency of user relevance scores. We also found that users tend to disagree more on subjective tags, such as ``good acting'', ``bad plot'' or ``quotable'' than on objective tags, such as ``animation'', ``cars'' or ``wedding'', but the disagreement of users regarding objective tags is also moderate.

Saturday 3 October 2020

YKI testi (actual tasks)

Tasks from the actual YKI test (as I remembered them)

YKI testi 03.10.2020

Kirjoittaminen

Tehtävä 1

Kutsut ystäväsi kilpailuun. Keksi itse:

Mikä kilpailu on?

Miksi kutsut ystäväsi?

Milloin ja missä kilpailu on?

Miten voit voittaa?

Friday 18 September 2020

Too wide lines (hbox overfull)


In latex, lines are sometimes wider than the line length (hbox overfull error). One way to avoid it is to use the parameter: \tolerance. The parameter changes between 0 and 10000.