public static Metric getMetric(String str) {
		String[] data = str.toLowerCase().split(":");
		String name = data[0];
		if (data.length == 1) {
			if (!map.containsKey(name)) {
				throw new IllegalArgumentException("Unrecognized metric name: " + name);
			} else {
				return map.get(name);
			}
		} else {
			if (name.equals("logloss")) {
				if (data[1].startsWith("t")) {
					return map.get("logloss_t");
				} else {
					return map.get(name);
				}
			} else if (map.containsKey(name)) {
				return map.get(name);
			}
		}
		return null;
	}