What can go wrong if we don't scale and center data in a predictive model?
Is it a good practice to always scale/normalize data for machine learning?
Often, TeX outputs underfull hbox and vbox warnings when running and in the generated log file. What are these and how can I get rid of them? How to setup Java-Home and Path in Ubuntu 12.04 Under Windows 7, how can I delete a folder whose name ends with "..."? Move all files of type to a new folder in windows 7 Sum of compact sets Let $A,B$ two non-empty compact subsets of a normed space X. How can we prove that the set $S=A+B=\{a+b : a \in A, b \in B\}$ is compact?  Here's my reasoning:  Let $\Omega = \{\Omega_1, \Omega_2,…\}$ be an open cover of $S$. $\Omega$ induces two open cover $X,Y$ respectively of $A,B$, where   $X_i = \{a \in A : a+b \in \Omega_i~~for~some~b\}$   $Y_i = \{b \in B : a+b \in \Omega_i~~for~some~a\}$  in practice $\Omega_i = X_i + Y_i$.  Now my idea is build a finite subcover this way: consider a finite subcover $X_F = \{X_j : j \in J\}$ where $J$ is a finite set of indices. If $Y_F = \{Y_j : j \in J\}$ is a finite subcover of $B$, then we are done as $\{\Omega_j : j \in J\}$ is a subcover of $\Omega$. Otherwise we can keep adding indexes to set $J$ until $Y_F$ becomes a finite subcover of $B$.   This is not too formal but I don't want to make a simple question unreadable, I think the idea should be clear.   Does this works? Is there a better/easier way to get the same result? Why is __init__() always called after __new__()? I'm just trying to streamline one of my classes and have introduced some functionality in the same style as the .  However, I'm a bit confused as to why __init__ is always called after __new__. I wasn't expecting this. Can anyone tell me why this is happening and how I can implement this functionality otherwise? (Apart from putting the implementation into the __new__ which feels quite hacky.)  Here's an example:  class A(object):     _dict = dict()      def __new__(cls):         if 'key' in A._dict:             print "EXISTS"             return A._dict['key']         else:             print "NEW"             return super(A, cls).__new__(cls)      def __init__(self):         print "INIT"         A._dict['key'] = self         print ""  a1 = A() a2 = A() a3 = A()   Outputs:  NEW INIT  EXISTS INIT  EXISTS INIT   Why? Correct spelling of "program" How to carry cologne bottles in hand luggage and prevent losses? How to correctly install libpng12-0 on the Ubuntu 19.10? For  I need to install libpng12-0 package on the Ubuntu 19.10 system.  I know that it is available .  So I have decided to download this package manually and install it by hand.  On previous Ubuntu versions (such as 18.04 LTS) this trick ends with success, but here on 19.10 it fails in very strange way:   wget http://mirrors.kernel.org/ubuntu/pool/main/libp/libpng/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb sudo apt-get install ./libpng12-0_1.2.54-1ubuntu1.1_amd64.deb  0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. Need to get 0 B/116 kB of archives. After this operation, 285 kB of additional disk space will be used. Get:1 /home/user/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb libpng12-0 amd64 1.2.54-1ubuntu1.1 [116 kB] Selecting previously unselected package libpng12-0:amd64. (Reading database ... 212864 files and directories currently installed.) Preparing to unpack .../libpng12-0_1.2.54-1ubuntu1.1_amd64.deb ... Unpacking libpng12-0:amd64 (1.2.54-1ubuntu1.1) ...  dpkg: error processing archive /home/user/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb (--unpack):  unable to install new version of '/lib/x86_64-linux-gnu/libpng12.so.0': No such file or directory No apport report written because the error message indicates an issue on the local system                                                                                          Errors were encountered while processing:  /home/user/libpng12-0_1.2.54-1ubuntu1.1_amd64.deb E: Sub-process /usr/bin/dpkg returned an error code (1)   What is wrong here? How can I get libpng12-0 installed on Ubuntu 19.10 system?    Note: the same happens on 19.04, but it is near EOL. How to avoid using sudo when working in /var/www? I want to stop having to use sudo everytime I work in /var/www. How can I do that? I simply want to put all of my sites into this directory and work with them without too much pain. The list view of Nautilus 3.6 shows the dates files were modified in a variety of ways: the hour and minute if modified on the current day, and the month and day if modified during the current year, and the year tacked on if modified during a previous year. I would like to see the entire date and time consistently on all the files (e.g.: Sat 20 Apr 2012 01:28:34 PM EDT).  I had this set up before, but I can't figure out how to do so with version 3.6. I did find this question, but the answers no longer apply to Nautilus 3.6:   How can I do so in Nautilus 3.6+? Ubuntu 14.04 System Logging I've set up an Ubuntu 14.04 Server (from an Ubuntu 12.04 Server) but today I wanted to look in the auth.log but this file is not used. It seems that ´syslog´ was deleted.  How does Ubuntu 14.04 log? I need this for a server.  Thank you. I am using ubercart guest checkout module. I am able to submit  the order as guest etc works fine.   After Reviewing the order and submitting it throws me this error   Recoverable fatal error: Argument 2 passed to db_query() must be an array, string given, called in /var/www/html/dev.demo.net/sites/all/modules/ubercart_guest_checkout/uc_guest_checkout.module on line 263 and defined in db_query() (line 2342 of /var/www/html/dev.demo.net/includes/database/database.inc).   This is the query which is causing that issue    db_query('UPDATE {users} SET name = "%s", mail = "%s" WHERE uid = %d', $name, $mail, $account-&gt;uid);   I tried to change this query like this  db_update('users') -&gt;fields(array(     'name' =&gt; $name,     'mail' =&gt; $mail )) -&gt;condition('uid',$account-&gt;uid,'=')        -&gt;execute();   still no luck, it throws me same above specified error.    How can i resolve the query of above one in order to avoid the error. Any suggestions w.r.t query will be nice.Thanks in advance. Complex number isomorphic to certain $2\times 2$ matrices? I have been trying to prove this, but I am having trouble understanding how to prove the following mapping I found is injective and surjective. Just as a side note, I am trying to show the complex ring is isomorphic to special $2\times2$ matrices in regard to matrix multiplication and addition. Showing these hold is simple enough.  $$\phi:a+bi \rightarrow \begin{pmatrix} a &amp; -b \\ b &amp; a \end{pmatrix}$$  This is what I have so far:  Injective: I am also confused over the fact that there are two operations, and in turn two neutral elements (1 and 0). Showing that the kernel is trivial is usually the way I go about proving whether a mapping is injective, but I just can't grasp this.  $$ \phi(z_1) = \phi(z_2) \implies \phi(z_1)\phi(z_2)^{-1} = I = \phi(z_1)\phi(z_2^{-1}) = \phi(z_2)\phi(z_2^{-1}).$$  So if we can just show that the kernel of $\phi$ is trivial, then it also shows that $z_1 = z_2$. The only complex number that maps to the identity matrix is one where $a = 1$ and $b = 0$, $a + bi = 1 + 0i = 1$.  Using a similar argument for addition we can just say that the only complex number $z$ such that $\phi(z) = 0\text{-matrix}$, is one where $a=0$ and $b=0$, $a+bi=0+0i=0$.   Surjective:  I forgot to add this before I posted, but I honestly don't really understand how to prove this because it just seems so obvious. All possible $2\times2$ matrices of that form have a complex representation because the complex number can always be identified by its real parts and since the elements of the $2\times2$ matrix are real then the mapping is obviously onto.  I have always had trouble understanding when I can say that I have "rigorously" proved something, so any help would be appreciated! How to determine the most likely reading frame of a DNA sequence? This question is from a past exam paper for an introductory bioinformatics module. I'm a computer scientist doing biology for the first time.  "A short bacterial gene has been sequenced, giving the following DNA sequence. Write out the 6 possible reading frames for this sequence and indicate which is the most likely protein translation of this sequence. Explain your reasoning for picking the given translation, and write all the translations in single letter amino acid code form.  5' - ttattcatccgccagcgccatgcgcgccat - 3'  "  I think I understand the 6 possible reading frames: three from the 5' end starting tta, tat and att; and three from the 3' end starting tac, acc and ccg.  I could also write out the translations for a given reading frame with a codon usage table. It's the most probable reading frame part I don't get. I thought perhaps I was looking for the longest open reading frame. I can only see one start codon (atg). What is the correct way to recognize the most probable reading frame?  I can't find this problem exactly on Biology Stack Exchange. I did find:     It made me wonder if I'm getting confused between "reading frame" and "open reading frame", this question only asks or the former.  Thanks! How to prove: if $a,b \in \mathbb N$, then $a^{1/b}$ is an integer or an irrational number? It is well known that $\sqrt{2}$ is irrational, and by modifying the proof (replacing 'even' with 'divisible by $3$'), one can prove that $\sqrt{3}$ is irrational, as well.  On the other hand, clearly $\sqrt{n^2} = n$ for any positive integer $n$.  It seems that any positive integer has a square root that is either an integer or irrational number.        How do we prove that if $a \in  \mathbb N$, then $\sqrt a$ is an integer or an irrational number?      I also notice that I can modify the proof that $\sqrt{2}$ is irrational to prove that $\sqrt[3]{2}, \sqrt[4]{2}, \cdots$ are all irrational.  This suggests we can extend the previous result to other radicals.        Can we extend 1? That is, can we show that for any $a, b \in \mathbb{N}$, $a^{1/b}$ is either an integer or irrational? I submitted a manuscript last year to an IEEE journal, and the paper was accepted for publication. I recently submitted a new manuscript to the same journal, but, this time, the paper was rejected, and I was told that I should submit to another journal since my paper was not within the journal's scope. The two papers both target similar applications. Furthermore, the second paper uses some work in the first paper, making substantial improvements at solving a much more difficult problem. Based on the reviewer's comments (and my own personal assessment), I do not believe that the work presented in the second paper was "incremental" in nature. Far from it. Two of the three reviewers gave positive reviews. The third reviewer, however, mentioned the "outside of journal's scope" issue and the associate editor and editor-in-chief both sided with the 3rd reviewer, and the paper was stopped dead in its tracks.  I'm scratching my head trying to come to terms with how in the world my first paper could be accepted by this journal, but the second paper focused on the same application space and achieving substantial improvements on a much more difficult problem (backed up with measured results) could be rejected. Any ideas? Automatic image format detection in PHP I am looking for a way to take a user uploaded image that is currently put in a temporary location ex: /tmp/jkhjkh78 and create a php image from it, autodetecting the format.  Is there a more clever way to do this than a bunch of try/catching with imagefromjpeg, imagefrompng, etc? literally as a hyperbole Possible Duplicate:          I have seen a lot of backlash in internet media against people using the word literally to mean something not literal. Something like "he was literally as big as a house" to mean someone was very big I think this comic sums up the anti literal movement well   Is this actually grammatically incorrect or can the word "literally" be a hyperbole strengthening a metaphor? I have realized that to pronounce the plural form of words ending in -th, we have to drop the letter "h". e.g. Months is pronounced /mʌnts/. But I have never seen this point mentioned in any context. I just want to make sure that this rule is correct and can be always applied.