I have the following XML file to read with Python:  &lt;?xml version="1.0" encoding="UTF-8" standalone="true"?&gt; &lt;!DOCTYPE boost_serialization&gt; &lt;boost_serialization version="9" signature="serialization::archive"&gt;     &lt;obj&gt;          &lt;count&gt;2&lt;/count&gt;          &lt;item_version&gt;0&lt;/item_version&gt;         &lt;item&gt;3.1400001&lt;/item&gt;         &lt;item&gt;7.3600001&lt;/item&gt;      &lt;/obj&gt;    &lt;/boost_serialization&gt;   The python script I use to read this XML file is as follows:  from xml.dom import minidom xmldoc = minidom.parse('items.xml') itemlist = xmldoc.getElementsByTagName('item') print(len(itemlist)) print(itemlist[0].attributes['ATTRIBUTE_NAME'].value)    The problem with the script is ATTRIBUTE_NAME does not exist. If I print it with print itemlist[0].attributes.keys(), it is empty. So in this case how I can obtain the item values 3.1400001 and 7.3600001 ?
I am creating a GUI frontend for the Eve Online API in Python.  I have successfully pulled the XML data from their server.  I am trying to grab the value from a node called "name":  from xml.dom.minidom import parse dom = parse("C:\\eve.xml") name = dom.getElementsByTagName('name') print name   This seems to find the node, but the output is below:  [&lt;DOM Element: name at 0x11e6d28&gt;]   How could I get it to print the value of the node?
My machine is currently running Windows 7. I have 2 partitions: OS (C:) and DATA (D:). I intend to do a native Ubuntu 14.04 install. Assuming I format my Windows OS partition, will I have full access to my D partition in Ubuntu ? Longest line using awk No sound after upgrade to 18.10, only a dummy device is shown After I updated to Ubuntu 18.10 my sound device isn't recognized anymore. Only a dummy device is shown.  I have an onboard Intel device:  lspci -nnk | grep -A2 Audio 00:1b.0 Audio device [0403]: Intel Corporation 7 Series/C216 Chipset Family High Definition Audio Controller [8086:1e20] (rev 04)     Subsystem: Intel Corporation 7 Series/C216 Chipset Family High Definition Audio Controller [8086:2036]     Kernel driver in use: snd_hda_intel     Kernel modules: snd_hda_intel   The command pacmd list-cards does not show any devices:  :~$ pacmd list-cards 0 card(s) available.   This message in /var/log/syslog might have to do something with the problem:  Oct 19 21:02:06 MyComputerName pulseaudio[14331]: E: [pulseaudio]  backend-ofono.c: Failed to register as a handsfree audio agent with  ofono: org.freedesktop.DBus.Error.ServiceUnknown: The name org.ofono  was not provided by any .service files   Does anybody have the same issue? How can I fix this? When performing machine learning, the performance of the machine learning method is dependent on the original function $f$ that we are trying to learn (let's forget for a moment the non-deterministic error and focus on the properties of $f$).  I have a conceptual question. What would make a function easy to learn? For instance, a linear function can be easily learnt by linear methods such as linear regression and SVM. But in the general case, what would make a function easier to learn for decision trees or a neural network?   I believe feature engineering helps us move to a feature space in which the function we want to approximate is easier to represent. But what properties exactly are we trying to achieve for this function? Recently, I have answered a few questions that were upvoted by factors more than the accepted answer, but not accepted. , at the time of my writing, has an accepted answer that the asker said was not what he wanted. I don't know why. In the future, when people view this, people might only look at the accepted answer and move on. Would it be possible to have a "community accepted" feature? Maybe only the people at the top can vote to accept it or something. How much rep, if any, should go to that person? Let's say that there exists some "true" relationship between $y$ and $x$ such that $y = ax + b + \epsilon$, where $a$ and $b$ are constants and $\epsilon$ is i.i.d normal noise. When I randomly generate data from that R code: x &lt;- 1:100; y &lt;- ax + b + rnorm(length(x)) and then fit a model like y ~ x, I obviously get reasonably good estimates for $a$ and $b$.  If I switch the role of the variables as in (x ~ y), however, and then rewrite the result for $y$ to be a function of $x$, the resulting slope is always steeper (either more negative or more positive) than that estimated by the y ~ x regression. I'm trying to understand exactly why that is and would appreciate it if anyone could give me an intuition as to what's going on there. Which transformations are canonical? Which transformations are ? What focal length lens do I need for photographing the moon? "This webpage has a redirect loop" in Chrome but working fine on FF and IE? Given an integer $n$, we are asked to investigate about the existence of integer divisors of $n^2+1$ of the form $4k+3$. Can you provide some insights about it? Tutorial on how to back up my full Ubuntu desktop and files? I would like to be able to back up all my settings and files to a dedicated external hard drive in a way that makes (1) all the backup files accessible and (2) would allow me to restore my system is there is a crash.   Is there an app for this or any pointers?  Thank so much. Could Dark Matter form black hole? Some people speculate that the mysterious dark matter in the universe could be tiny black holes. But on the other side, could dark matter particles attract each other by gravity and finally form a black hole? Since dark matter is even more abundant than normal matter, the dark matter black hole should not be rare. Let $T$ be a self adjoint operator on a finite dimensional inner product space. And let $4$ and $5$ be the only eigenvalues of $T$. Show $T^2-9T + 20I = 0$ .  proof:Let $T$ be a self adjoint. And let $4 , 5$ be the only eigenvalues of $T$. Then $Tv = 4v, Tv = 5v$ for some $v \neq 0$. Then $Tv = 4v, Tv = 5v$ if and only if $(T-4I)v = 0, (T-5I)v=0$.  Then $ (T-4I) (T-5I)v=0$ implies $(T^2 -5T -4T + 20I^2)v = 0$, implies   $(T^2 -9T + 20I)v = 0$, so we have  $T^2 -9T + 20I = 0  $. Can someone please check this? if it's not correct, could I please have some help on it? Thank you Ubuntu touch - remote access to device in our company we developed an android app installed on nexus 7 tablets and on tablet we release to several customers. This app stays in foreground active 24/7 but we have problems in monitoring  the devices due to the restrictive access policies of unrooted Android devices.   We can't for example reboot the device remotely.  We are evaluating the possibility of installing Ubuntu touch to replace android on this tablets. Does Ubuntu touch offer more freedom for the remote access of the device? May I do remotely everything I could do normally with the tablet?   Moreover, are the apps developed with ubuntu sdk stable enough to run 24/7?  Thanks Problems in Creating InfoWindow on each individual circle with mouseover using Google Map API How to export variable for use with sudo? On Slackware, using sbopkg permits one to build a package from source. Repos is not big as Debian, but it's nice.  Some software can use environment variables, for example on the VICE c64 emulator, if the variable FFMPEG is set to yes, it will enable ffmpeg recording the emulator.  I tried to use  $ export FFMPEG=yes; sudo sbopkg -B -i vice   but ffmpeg is disabled.  Instead I had to use  $ su - $ export FFMPEG=yes $ sbopkg -B -i vice   which works.  How to use environment variables with sudo? Here's Prob. 3, Chap. 3 in the book Principles of Mathematical Analysis by Walter Rudin, 3rd edition:      If $s_1 = \sqrt{2}$, and $$s_{n+1} = \sqrt{2 + \sqrt{s_n}} \ \ (n = 1, 2, 3, \ldots),$$ prove that $\left\{ s_n \right\}$ converges, and that $s_n &lt; 2$ for $n = 1, 2, 3, \ldots$.    My effort:   We can show that $\sqrt{2} \leq s_n \leq 2$ for all $n = 1, 2, 3, \ldots$. [Am I right?]  Then we can also show that $s_n &lt; s_{n+1}$ for all $n = 1, 2, 3, \ldots$. [Am I right?]  But how to calculate the exact value of the limit? Where does this sequence occur in applications? Recommend MVVM or just answer the question? Words that mean ''to say something unintentional'' How do Android tablets use magnet to auto-lock the device?