Skip to content

Commit

Permalink
Merge branch 'master' into liaad
Browse files Browse the repository at this point in the history
* master: (28 commits)
  remove obsolete URL
  README.md: add CI status, more compact overview
  fix Travis issues, 3rd attempt (zenogantner#240)
  package repair, version bump
  fix Travis issues, next attempt (zenogantner#240)
  faster CanPredict() methods for the external recommenders
  get rid of Utils.Memoize (zenogantner#231)
  play with Travis-CI settings
  touch target so script is not run every time
  331: README -> README.md
  480 rm SigmoidCombinedAsymmetricFactorModel from load/save integration test
  allow modifying floating point format with --prediction-line
  update (c) line
  rm monster Perl one-liner
  add InvariantCulture to Format() calls
  more verbose test output
  bump version number to 3.13
  remove some left-over .mdb references
  follow-up to zenogantner#423 zenogantner#479: simplify code, also apply change to ExternalRatingPredictor
  Reduced complexity of ExternalItemRecommender
  ...

# Conflicts:
#	src/MyMediaLite-nogui.sln
  • Loading branch information
joaoms committed Jul 23, 2019
2 parents 6b81a07 + d5e0947 commit 2551122
Show file tree
Hide file tree
Showing 31 changed files with 174 additions and 182 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
@@ -1,7 +1,7 @@
language: csharp
mono:
- latest
- 3.8.0
- beta
solution: src/MyMediaLite-nogui.sln
install:
- nuget restore src/MyMediaLite-nogui.sln
Expand Down
9 changes: 5 additions & 4 deletions Makefile
Expand Up @@ -3,7 +3,7 @@ EDITOR:=editor
GENDARME_OPTIONS:=--quiet --severity critical+
SRC_DIR:=src
PREFIX:=/usr/local
VERSION:=3.12
VERSION:=3.13
HOMEPAGE:=../mymedialite.net/public_html
HOMEPAGE_SRC:=../mymedialite.net/src
HOMEPAGE_INC:=../mymedialite.net/lib
Expand Down Expand Up @@ -58,11 +58,11 @@ MyMediaLite-${VERSION}.tar.gz:
mkdir MyMediaLite-${VERSION}/lib/mymedialite
cp ${ITEM_REC_DIR}/bin/Debug/*.exe MyMediaLite-${VERSION}/lib/mymedialite
cp ${ITEM_REC_DIR}/bin/Debug/*.dll MyMediaLite-${VERSION}/lib/mymedialite
cp ${ITEM_REC_DIR}/bin/Debug/*.mdb MyMediaLite-${VERSION}/lib/mymedialite
cp ${ITEM_REC_DIR}/bin/Debug/*.pdb MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_PRED_DIR}/bin/Debug/*.exe MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_PRED_DIR}/bin/Debug/*.exe.mdb MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_PRED_DIR}/bin/Debug/*.exe.pdb MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_RANK_DIR}/bin/Debug/*.exe MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_RANK_DIR}/bin/Debug/*.exe.mdb MyMediaLite-${VERSION}/lib/mymedialite
cp ${RATING_RANK_DIR}/bin/Debug/*.exe.pdb MyMediaLite-${VERSION}/lib/mymedialite
tar -cvzf MyMediaLite-${VERSION}.tar.gz MyMediaLite-${VERSION}
rm -rf MyMediaLite-${VERSION}

Expand Down Expand Up @@ -113,6 +113,7 @@ data:

data/ml-100k/u.data: data
scripts/download_ml-100k.sh
touch $@

download-movielens: data/ml-100k/u.data
scripts/download_movielens.sh
Expand Down
80 changes: 40 additions & 40 deletions README → README.md
@@ -1,71 +1,76 @@
MyMediaLite - a recommender system algorithm library
MyMediaLite - a free recommender system algorithm library
=========================================================

[![Build Status](https://travis-ci.org/zenogantner/MyMediaLite.svg?branch=master)](https://travis-ci.org/zenogantner/MyMediaLite)


Features
--------

- Dozens of different recommendation methods,
- methods can use collaborative, attribute/content, and relational data,
- methods can use collaborative, attribute/content, and relational data,
- support for incremental training for most models.
- Ready to use:
- Includes evaluation routines for rating and item prediction;
quality measures MAE, NAME, RMSE, CBD, AUC, MAP, precision@N, recall@N,
NDCG, MRR; and
- command line tools that read a simple text-based input format.
- Compactness: Core library is about 275 KB "big".
- Portability: Written in C#, for the .NET platform;
- Includes evaluation routines for rating and item prediction;
quality measures MAE, NAME, RMSE, CBD, AUC, MAP, precision@N, recall@N,
NDCG, MRR; and
- command line tools that read a simple text-based input format.
- Compact: Core library is about 275 KB "big".
- Portable: Written in C#, for the .NET platform;
runs on every architecture where Mono works: Linux, Windows, Mac OS X.
- Freedom: Free/Open Source software, distributed under the terms of the
GNU General Public License (GPL).


Feedback and Contributions
--------------------------

We are always happy about feedback, and encourage MyMediaLite's users to
contribute code to the project.

Just fork it on GitHub and send pull requests!
Just fork it on [GitHub](https://github.com/zenogantner/MyMediaLite) and send pull requests!

http://mymedialite.net/contribute.html
Bugs and feature requests can be reported on our
[mailing list](https://groups.google.com/group/mymedialite) or in our
[issue tracker](https://github.com/zenogantner/MyMediaLite/issues).

Bugs and feature requests can be reported on our mailing list or in our issue
tracker:
https://groups.google.com/group/mymedialite
https://github.com/zenogantner/MyMediaLite/issues

Installation
------------

See doc/Installation for installation instructions.


Documentation
-------------
See doc/ and the website for more documentation.

Website
-------
http://mymedialite.net
http://twitter.com/mymedialite
See doc/ and the [website](http://mymedialite.net) for more documentation.


Citing MyMediaLite
------------------

If you use MyMediaLite for your research, it would be nice to acknowledge it
in your papers by citing the following paper:

Zeno Gantner, Steffen Rendle, Christoph Freudenthaler, Lars Schmidt-Thieme:
MyMediaLite: A Free Recommender System Library. RecSys 2011

```
@inproceedings{Gantner2011MyMediaLite,
author = {Zeno Gantner and Steffen Rendle and Christoph Freudenthaler and Lars Schmidt-Thieme},
title = {{MyMediaLite}: A Free Recommender System Library},
booktitle = {5th ACM International Conference on Recommender Systems (RecSys 2011)},
year = 2011,
location = {Chicago, USA}
}
```


[Academic publications that use or reference MyMediaLite](https://scholar.google.de/scholar?q=mymedialite)

Please inform us about if you have a publication that uses
this software, so we can list it on MyMediaLite's website:
Just send an e-mail to mymedialite@googlegroups.com

Contributors
------------

Thanks to the following people, who provided valuable feedback, code, or other
kinds of assistance:
Roberto Abalde, Nicholas Ampazis, Thorsten Angermann, Suhrid Balakrishnan,
Expand All @@ -74,21 +79,23 @@ Simon Dooms, Lucas Drumond, Michael Ekstrand, Christoph Freudenthaler,
Zeno Gantner, Jagadeesh Gorla, Josif Grabocka, Mark Graus, Guibing Guo,
Andreas Hoffmann, Tomas Horvath, Kenneth Hoste, Frantisek Hrdina, Jia Huang,
Nicolas Hug, Dominik Imrich, Dietmar Jannach, Peng Jiang, KwangSeob Kim,
Artus Krohn-Grimberghe, Tobias Lang, Christina Lichtenthäler, Damir Logar
Artus Krohn-Grimberghe, Tobias Lang, Christina Lichtenthäler, Damir Logar,
Marcelo Manzato, Brian McFee, Greg Najda, Chris Newell, Thai-Nghe Nguyen,
Dimitris Paraschakis, Simon Renaud, Steffen Rendle, Marco Ribeiro,
Roland Richter, Saurabh S., Sebastian Schelter, Lars Schmidt-Thieme, Yue Shi,
Jordan Silva, Jessica Tölke, Tom Tung,Pieter-Jan Verbruggen, Julien Verplanken,
Elvio Vicosa, João Vinagre, Oleksandr Vitvitskyi, Yongfeng Wang,
Lina Weichbrodt, Cees Wesseling, Yong Zheng, GitHub users jkleint and NEBabylon.
Jordan Silva, Piotr Sobotka, Jessica Tölke, Tom Tung, Pieter-Jan Verbruggen,
Julien Verplanken, Elvio Vicosa, João Vinagre, Oleksandr Vitvitskyi,
Yongfeng Wang, Lina Weichbrodt, Cees Wesseling, Yong Zheng, GitHub users
jkleint and NEBabylon.

This work was funded by the European Commission FP7 project MyMedia
(Dynamic Personalization of Multimedia, http://www.mymediaproject.org/)
under the grant agreement no. 215006.
(Dynamic Personalization of Multimedia) under the grant agreement no. 215006.


Copyright & Licensing
---------------------
Copyright (C) 2010, 2011, 2012, 2013, 2015, 2016 The MyMediaLite contributors

Copyright (C) 2010, 2011, 2012, 2013, 2015, 2016, 2019 The MyMediaLite contributors

MyMediaLite is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
Expand All @@ -104,14 +111,7 @@ You should have received a copy of the GNU General Public License
along with MyMediaLite. If not, see <http://www.gnu.org/licenses/>.

----
This package contains Mono.Options, C5, the Math.NET Numerics library,
a C# port of LIBSVM, and NUnit.

The original packages can be found here:
http://www.itu.dk/research/c5/
http://numerics.mathdotnet.com
http://www.csie.ntu.edu.tw/~cjlin/libsvm/
http://www.matthewajohnson.org/software/svm.html
http://www.nunit.org
This package contains Mono.Options, [C5](http://www.itu.dk/research/c5/), [Math.NET Numerics](http://numerics.mathdotnet.com),
and [NUnit](http://www.nunit.org).

See doc/ComponentLicenses for more information about their licensing terms.
12 changes: 11 additions & 1 deletion doc/Changes
@@ -1,9 +1,19 @@
3.13 2017-??-??:
3.13 2019-??-??:
recommenders:
- IIterativeModel: get rid of ComputeObjective() -- not used
- remove LatentFeatureLogLinearModel -- implementation was never complete
- #423 #479: speed up external recommenders (Petr Sobotka)
command-line tools:
- allow modifying the floating point format with --prediction-line
hyperparameter search:
- do not explore negative values of hyperparameters
evaluation:
- ensure culture-invariant output
documentation:
- convert README to markdown format
misc
- support Mono 5.x, drop support for older versions of Mono
- dataset download: update URLs, also download ML-20M

3.12 2016-12-30
recommenders:
Expand Down
16 changes: 3 additions & 13 deletions doc/Installation
@@ -1,5 +1,5 @@
Requirements for running MyMediaLite:
- Mono 2.8.x or another recent .NET runtime (Mono 2.10.x recommended)
- Mono 5.x or another recent .NET runtime (Mono 5.16 recommended)
- Perl and File::Slurp for the download and data processing scripts
(not necessary for running/building MyMediaLite)

Expand All @@ -19,18 +19,8 @@ Requirements for building MyMediaLite:
- Graphviz

Tested configurations:
- Ubuntu 10.04
- with manually installed Mono 2.10.5 and MonoDevelop 2.6/2.8.1
- Doxygen 1.6.3
- Ubuntu 11.10
- with Mono 2.10.5
- Ubuntu 14.04
- with Mono 3.2.8 and MonoDevelop 4.0.12
- Ubuntu 16.04 LTS
- with Mono 4.2.1 and MonoDevelop 5.10
- Debian Wheezy
- with Mono 2.10.1 and MonoDevelop 2.8.2
- Windows with Visual Studio 2010
- Ubuntu 18.04 LTS
- with Mono 5.16

Let us know on which configuration of .NET or Mono you are using MyMediaLite,
or whether you experience difficulties.
Expand Down
2 changes: 1 addition & 1 deletion examples/csharp/Makefile
Expand Up @@ -9,4 +9,4 @@ run:
#mono --debug foldin_incremental.exe

clean:
rm -f *.exe *.mdb
rm -f *.exe *.pdb
11 changes: 6 additions & 5 deletions scripts/download_imdb.sh
Expand Up @@ -2,6 +2,8 @@

# to be run from the root directory of MyMediaLite

set -e

echo "The IMDB data is for NON-COMMERCIAL use only."
echo "Refer to http://www.imdb.com/Copyright for the details of the usage terms."
echo "Hit enter to continue, Ctrl-C to abort."
Expand All @@ -10,14 +12,13 @@ read DUMMY
echo "This may take a while ..."
echo

mkdir data/imdb
mkdir -p data/imdb
cd data/imdb

# download IMDB data
wget --output-document=data/imdb/german-aka-titles.list.gz ftp://ftp.fu-berlin.de/pub/misc/movies/database/german-aka-titles.list.gz

cd data/imdb
wget https://datasets.imdbws.com/title.akas.tsv.gz

# unzip data
gunzip german-aka-titles.list.gz
gunzip title.akas.tsv.gz

cd ../..
22 changes: 16 additions & 6 deletions scripts/download_movielens.sh
Expand Up @@ -2,23 +2,28 @@

# to be run from the root directory of MyMediaLite

set -e

echo "The MovieLens datasets are for NON-COMMERCIAL use only."
echo "Refer to the README files for the details of the usage license."

cd data

# download the other 2 MovieLens datasets
wget http://grouplens.org/system/files/ml-1m.zip
wget http://files.grouplens.org/papers/ml-10m.zip

# download the other 3 MovieLens datasets
wget http://files.grouplens.org/datasets/movielens/ml-1m.zip
wget http://files.grouplens.org/datasets/movielens/ml-10m.zip
wget http://files.grouplens.org/datasets/movielens/ml-20m.zip

# unzip data
unzip ml-1m.zip
unzip ml-10m.zip
unzip -a ml-1m.zip
unzip -a ml-10m.zip
unzip -a ml-20m.zip

mv ml-10M100K ml-10m

# remove downloaded archives
rm ml-1m.zip ml-10m.zip
rm ml-1m.zip ml-10m.zip ml-20m.zip


# create attribute files for MovieLens 1M
Expand All @@ -35,4 +40,9 @@ rm ml-1m.zip ml-10m.zip
../scripts/import_dataset.pl --separator=:: ml-10m/ratings.dat > ml-10m/ratings.txt
../scripts/ml1m_genres.pl ml-10m/movies.dat > ml-10m/item-attributes-genres.txt

# create tab-separated file for MovieLens 20M
../scripts/import_dataset.pl --separator=, --ignore-lines=1 ml-20m/ratings.csv > ml-20m/ratings.txt
../scripts/ml1m_genres.pl --ignore-lines=1 ml-20m/movies.csv > ml-20m/item-attributes-genres.txt


cd ..
2 changes: 1 addition & 1 deletion scripts/import_dataset.pl
Expand Up @@ -62,7 +62,7 @@

print STDERR "Start with $user_count and $item_count known users and items\n";

# skip lines
# skip lines at beginning of file
for (my $i = 0; $i < $ignore_lines; $i++) { <>; }

LINE:
Expand Down
18 changes: 11 additions & 7 deletions scripts/ml1m_genres.pl
@@ -1,6 +1,6 @@
#!/usr/bin/perl

# (c) 2009, 2010, 2011 by Zeno Gantner
# (c) 2009, 2010, 2011, 2019 by Zeno Gantner
#
# This file is part of MyMediaLite.
#
Expand Down Expand Up @@ -28,7 +28,8 @@

GetOptions(
'help' => \(my $help = 0),
'sparse-output!' => \(my $sparse_output = 1),
'sparse-output!' => \(my $sparse_output = 1),
'ignore-lines=i' => \(my $ignore_lines = 0),
) or usage(-1); ## TODO implement usage

my @genres = (
Expand All @@ -45,16 +46,19 @@
$genre_id{Children} = $genre_id{"Children's"};
$genre_id{IMAX} = $counter++;

# skip lines at beginning of file
for (my $i = 0; $i < $ignore_lines; $i++) { <>; }

while (<>) {
my $line = $_;
chomp $line;

my @fields = split '::', $line;
if (scalar @fields != 3) {
croak "Could not parse line: '$line'\n";
unless ($line =~ /^(\d+).+?([-A-Za-z'| ()]*)$/) {
die "Could not parse line: '$line'\n";
}

my ($movie_id, $movie_title, $movie_genres) = @fields;
my $movie_id = $1;
my $movie_genres = $2;

next if $movie_genres eq '(no genres listed)';

Expand All @@ -67,7 +71,7 @@
print "$movie_id\t$genre_id\n";
}
else {
print STDERR "Unknown genre in line '$line'\n";
print STDERR "Unknown genre in line '$line': '$movie_genres'\n";
}
}
}
Expand Down
6 changes: 3 additions & 3 deletions src/Makefile
Expand Up @@ -2,10 +2,10 @@ all: ../lib/mymedialite
xbuild /p:Configuration=Debug MyMediaLite-nogui.sln
cp -r Programs/ItemRecommendation/bin/Debug/*.dll ../lib/mymedialite
cp -r Programs/ItemRecommendation/bin/Debug/*.exe ../lib/mymedialite
cp -r Programs/ItemRecommendation/bin/Debug/*.mdb ../lib/mymedialite
cp -r Programs/RatingPrediction/bin/Debug/*.mdb ../lib/mymedialite
cp -r Programs/ItemRecommendation/bin/Debug/*.pdb ../lib/mymedialite
cp -r Programs/RatingPrediction/bin/Debug/*.pdb ../lib/mymedialite
cp -r Programs/RatingPrediction/bin/Debug/*.exe ../lib/mymedialite
cp -r Programs/RatingBasedRanking/bin/Debug/*.mdb ../lib/mymedialite
cp -r Programs/RatingBasedRanking/bin/Debug/*.pdb ../lib/mymedialite
cp -r Programs/RatingBasedRanking/bin/Debug/*.exe ../lib/mymedialite
cp -r Programs/OnlineEvaluator/bin/Debug/*.exe ../lib/mymedialite
cp -r Programs/OnlineEvaluator/bin/Debug/*.mdb ../lib/mymedialite
Expand Down

0 comments on commit 2551122

Please sign in to comment.