Why is "condensed nearest neighbour" Parametric? Definition of "condensed nearest neighbour", at training time it chooses the c "best" training examples (where c is a hyper-parameter), and at test time uses the usual KNN prediction but based only on these c training examples.   So far, I looked-up many references and websites and researched on how to determine if a method is between parametric or non-parametric. I came up with below definitions,     A parametric algorithm has a fixed number of parameters. In contrast, a non-parametric algorithm uses a flexible number of parameters, and the number of parameters often grows as it learns from more data.   From .  Moreover, I found,     A parametric model, we have a finite number of parameters, and in nonparametric models, the number of parameters is (potentially) infinite.    From .  My question is, why do we count it as a Parametric model?
Parametric vs non-parametric machine learning methods I looked-up many references and websites and researched on how to determine if a method is between parametric or non-parametric. I came up with below definitions,     A parametric algorithm has a fixed number of parameters. In contrast, a non-parametric algorithm uses a flexible number of parameters, and the number of parameters often grows as it learns from more data.   From .  Moreover, I found,     A parametric model, we have a finite number of parameters, and in nonparametric models, the number of parameters is (potentially) infinite.    From .  And many other methods of determination, though the problem is none of them can helo ones to determine if a certain hypothetical method is parametric or not. (For instance, why k-means' number of parameters are constant but KNN is variable or basically what do we call a parameter and what we do not?)
Backup of clients' directory to Windows Server 2008 We have a machine running Windows Server 2008, and we need to take backup of folder from a desktop on LAN. This folder is not shared.   Is there any tool or software to do this, or can a scheduled task be made which should automatically take the backup of that folder date-wise &amp; make a copy on server? Ie can we do it through Schedule Tasks option ?  Desktop systems have Windows Vista/Windows 7. Center figure that is wider than \textwidth A single word for someone who spends their wealth very foolishly Proof: $\cos^p (\theta) \le \cos(p\theta)$ I came across this problem when I was at a book store inside of a book made to prepare Berkeley graduates to pass a mandatory exam. I wanted to buy the book, but, alas, I didn't have the money (forty bucks is a lot of money when you don't have a job). So I took my phone out and started taking as many pictures as I could. Unfortunately, I didn't take any pictures of the solutions!  Enough backstory. Time for math. The problem is as follows:  Prove that $\cos^p( \theta) \le \cos(p \theta)$ if $0\le\theta\le\frac\pi2$ and $0\le p\le 1$.  I tried using the series expansion for cosine, but that seemed to be a dead end. Then I tried using Euler's theorem, but I got stuck. Then I got distracted and started to think about other cosine identities. For example, $$\cos\left(\frac\theta2\right)=\pm\sqrt{\frac{1+\cos(\theta)}{2}}.$$ Then what is $\cos(\frac\theta3)$ equal to? I tried to figure it out then I realized that I needed to find the root of a cubic polynomial. Then I realized that I'm better at staying focused than finding the roots of cubic polynomials.  Anyways, a proof would be nice here. I really appreciate any hints or answers. I apologize for my digressions! Is there any possibility of setting up two factor authentication (2FA) for Stack Exchange OpenID authentication?  I could just use my (already 2FA-enabled) Google account for Stack Exchange, but I would prefer to continue use Stack Exchange OpenID.  After  (which, I appreciate, didn't affect Stack Exchange, as you use IIS and Schannel, not OpenSSL), there have been a lot of recommendations to change passwords and to enable 2FA where possible.  So, what are the chances of a text-messaging-based or Google-Authenticator-based 2FA for Stack Exchange? I've often come across posts on forums or other websites where you see people joking in such a manner about running/logging in as root as if it's something awful and everyone ought to know about it. However, there isn't much that a search reveals on the matter.   It may be widely known to Linux experts, but I really don't know why. I remember always running as root when I first tried Linux years ago (Redhat and Mandrake) and don't remember running into any problems because of that.   There are actually some distros that have a bright red background with alert signs all over it as wallpaper for the root user (SuSe?). I still use the "Administrator" account for regular use on my Windows installation and haven't ever run into any problems there either. Should Stack Overflow be redesigned with a responsive layout? Counting surjective functions We have $r$ objects and $n$ boxes. I have to count all the combinations possible if the objects and boxes could be both different. If that happens I can count the number of variations from $n$ to $r$ (number of functions between objects and boxes). I mean, $n^r$.  But if I have to count all the combinations possible if anyone of the boxes is empty ($r\ge n$). Now I have to count the surjective functions.  For example if I have $r$ objects and 1 box. The number of surjective functions is 1. Then, if I have $r$ objects and 2 boxes, the number of surjective functions is $2^r-2$. And finally if I have $r$ objects and 3 boxes, I will count $3^r-2\cdot[3\cdot2^r-3]$. How do I get the formula for $r$ objects and $n$ boxes? I have a issue with my Drupal installation, for example:   when I enable or disable the modules, It redirects me to a blank page, when I create a new content type and save it, redirects me to a blank page, when I add a new view and save it, it redirects me to a blank page, when I try to clear the cache, it redirects me back to a blank page, or in similar cases.   Basically all the confirmation pages redirect me to a white screen. When I refresh it again, it shows me the page. I tried to increase the PHP memory value but it doesn't help.  Are there any other solutions for this?  The error which I'm having:      Fatal error: Allowed memory size of 100663296 bytes exhausted (tried to allocate 8192 bytes) in sites/all/modules/views/plugins/views_plugin_localization_none.inc on line 1 Analytic continuation of function continuous on boundary Suppose one has a function $f$ in the disc algebra ie: $f$ is continuous on $|z|\leq1$ and holomorphic in $|z|&lt;1$. I wondered, can $f$ always be extended to a holomorphic function on some region containing the boundary (ie: $T$ the unit circle). If not can you give me an example? Thank you, Serializing anonymous delegates in C# Foo* set = new Foo[100]; // ... delete [] set;   You don't pass the array's boundaries to delete[]. But where is that information stored? Is it standardised? Generate random numbers uniformly over an entire range I need to generate random numbers within a specified interval, [max;min].  Also, the random numbers should be uniformly distributed over the interval, not located to a particular point.  Currenly I am generating as:  for(int i=0; i&lt;6; i++) {     DWORD random = rand()%(max-min+1) + min; }   From my tests, random numbers are generated around one point only.  Example min = 3604607; max = 7654607;   Random numbers generated:  3631594 3609293 3630000 3628441 3636376 3621404   From answers below: OK, RAND_MAX is 32767. I am on C++ Windows platform. Is there any other method to generate random numbers with a uniform distribution? How to customize my titlepage? Using strtok with a std::string I have a string that I would like to tokenize. But the C strtok() function requires my string to be a char*. How can I do this simply?  I tried:  token = strtok(str.c_str(), " ");    which fails because it turns it into a const char*, not a char* What is time dilation really? Exploring $ \sum_{n=0}^\infty \frac{n^p}{n!} = B_pe$, particularly $p = 2$. I was exploring the fact that $$ \sum_{n=0}^\infty \frac{n^p}{n!} = B_pe,$$ where $B_n$ is the $n$th Bell number.   I found this result by exploring the series on wolframalpha and looking up the sequence of numbers generated. I have no experience with Bell numbers other than knowing that they represent the number of ways of partitioning a set.   What I tried  Looking at the base case we can verify $$\sum_{n=0}^\infty \frac{n}{n!} = \sum_{n=1}^\infty \frac{1}{(n-1)!} = e. $$  But then I realize that $n^2$ is going to be difficult.  Specifically what I want  I am doing this for fun, so I just want to glean some sort of lesson out of this. Resources that let me learn for myself are just as good!   An accepted answer will have any one of the following:   A proof that $\sum_{n = 0}^{\infty} \frac{n^2}{n!} = 2e$ (this interests me a lot) A description of why this series is related to Bell numbers and the number of partitions of a set A link to some resource that introduces Bell numbers and/or their connection to this series. Database general error: 2006 MySQL server has gone away Recently I started getting an error every time I try and add a content no matter what type.  This is the error that shows up in the browser:     Additional uncaught exception thrown while handling exception.        Original   PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT COUNT(cid) FROM {comment} WHERE status = :status; Array ( [:status] =&gt; 0 ) in comment_count_unpublished() (line 313 of /Applications/MAMP/htdocs/modules/comment/comment.module).        Additional      PDOException: SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: INSERT INTO {watchdog} (uid, type, message, variables, severity, link, location, referer, hostname, timestamp) VALUES (:db_insert_placeholder_0, :db_insert_placeholder_1, :db_insert_placeholder_2, :db_insert_placeholder_3, :db_insert_placeholder_4, :db_insert_placeholder_5, :db_insert_placeholder_6, :db_insert_placeholder_7, :db_insert_placeholder_8, :db_insert_placeholder_9); Array ( [:db_insert_placeholder_0] =&gt; 1 [:db_insert_placeholder_1] =&gt; php [:db_insert_placeholder_2] =&gt; %type: !message in %function (line %line of %file). [:db_insert_placeholder_3] =&gt; a:6:{s:5:&quot;%type&quot;;s:12:&quot;PDOException&quot;;s:8:&quot;!message&quot;;s:154:&quot;SQLSTATE[HY000]: General error: 2006 MySQL server has gone away: SELECT COUNT(cid) FROM {comment} WHERE status = :status; Array ( [:status] =&amp;gt; 0 ) &quot;;s:9:&quot;%function&quot;;s:27:&quot;comment_count_unpublished()&quot;;s:5:&quot;%file&quot;;s:56:&quot;/Applications/MAMP/htdocs/modules/comment/comment.module&quot;;s:5:&quot;%line&quot;;i:313;s:14:&quot;severity_level&quot;;i:3;} [:db_insert_placeholder_4] =&gt; 3 [:db_insert_placeholder_5] =&gt; [:db_insert_placeholder_6] =&gt; ; [:db_insert_placeholder_7] =&gt;  [:db_insert_placeholder_8] =&gt; 127.0.0.1 [:db_insert_placeholder_9] =&gt; 1338336955 ) in dblog_watchdog() (line 154 of /Applications/MAMP/htdocs/modules/dblog/dblog.module).   I also get the following error in my php error file:     PHP Fatal error:  Uncaught exception 'PDOException' with message 'SQLSTATE[HY000]: General error: 2006 MySQL server has gone away' in /Applications/MAMP/htdocs/includes/database/database.inc:2136        Stack trace:   0 /Applications/MAMP/htdocs/includes/database/database.inc(2136): PDOStatement->execute(Array)   1 /Applications/MAMP/htdocs/includes/database/database.inc(664): DatabaseStatementBase->execute(Array, Array)   2 /Applications/MAMP/htdocs/includes/database/database.inc(2315): DatabaseConnection->query('SELECT expire, ...', Array, Array)   3 /Applications/MAMP/htdocs/includes/lock.inc(167): db_query('SELECT expire, ...', Array)   4 /Applications/MAMP/htdocs/includes/lock.inc(146): lock_may_be_available('theme_registry:...')   5 /Applications/MAMP/htdocs/includes/theme.inc(447): lock_acquire('theme_registry:...')   6 /Applications/MAMP/htdocs/includes/bootstrap.inc(427): ThemeRegistry->set(Array)   7 [internal function]: DrupalCacheArray->__destruct()   8 {main}         thrown in /Applications/MAMP/htdocs/includes/database/database.inc on line 2136   I am having a little trouble deciphering these error messages. Could anyone help me understand what's going on here? I am trying to check if the user_picture field is empty using the twig template, but I am not able to do this.  I tried lots of ways:-  {% if node.user_picture.value %} {% if node.user_picture.entity %} {% if content.user_picture.value %} {% if content.user_picture|render.entity %} {% if content.user_picture|render %}     Sample of code:    {% if node.user_picture.value %}     &lt;p&gt;User-picture 02&lt;/p&gt;     {{ user_picture }}   {% else %}     &lt;p&gt;Anymonus-picture 02&lt;/p&gt;     &lt;div&gt;       &lt;a href="#"&gt;&lt;img src="{{base_path}}/WEBSITE/themes/THEME/images/anonymous.jpg" alt=""&gt;&lt;/a&gt;     &lt;/div&gt;   {% endif %} Great Theorem - Help name the Sci-fi book read long ago I'm trying to find a book I read long back. This book may have won a Hugo/Nebula (Trust me I've googled to death this one!).  Don't remember much of the story (that's why I want to re-read it). What I remember is that some of the powers in the book are called "Gods". And they have brains the size of the planets (or planets being their brains).  The protagonist in the climax, solves a theorem (The Great Theorem, perhaps) by remembering one of the obscure theorems (Jacuzi (?)) and incorporating it. This [Great] theorem helps spaceships helps find the shortest route from point A to B. He surprises the antagonist by reaching the vantage point quickly with the help of his new knowledge, and blasts his enemy's spaceship.  The ending of the book - as I remember it is - that the protagonist wants to become a God himself.  Please let me know the title &amp; author of this book if you've read it.  PS #1:  BTW, It's not Asimov's The Gods Themselves :) PS #2:  It's published at the least before 1998