Octave contourf() Not Coloring in the Line - octave

I'm having trouble filling in my curves using contourf() on Octave. I'm running Octave 3.6.4 on Mac OS X 10.8.5.
When I use contour(x,fp,data3) I get the following, which is correct:
[Contour plot of data, not filled]
However, when I want try contourf(x,fp,data3) in order to fill in the gaps I get this monstrosity:
Contourf plot of data, filled, but not correct
What can I do to fix this? I've read the contourf() documentation and can't see anything there that I'm missing. Any advice would be helpful.
Thanks!
P.S. Here's a link to a smaller version of the data file: https://www.dropbox.com/s/lmvdzi7l42tasr8/Ch942.csv?dl=0. The whole file is huge, so this represents the first few lines but still shows the problem when plotted in Octave.
Unfortunately I don't have enough reputation points to post more than two links, so I've deleted the contour() plot that looks right, but isn't filled in. Sorry.

Related

PlotlyJS.jl "savehtml" not defined

I need to share an interactive plot made using the PlotlyJS package in Julia. According to the documentation of the package PlotlyJS.jl, I need to use the "savehtml" function and set "js" argument to ":embed" in order to view it offline (screenshot attached). However, I got an error "UndefVarError: savehtml not defined". Can anyone tell me what may cause this problem?
FYI, the "savefig" function can save the plot into an HTML but the HTML cannot be viewed on other machines.
It is also acceptable if there is another way to save an HTML plot that can be assessed from other machines. The interactive plot is generated by PlotlyJS.jl.
Thanks very much in advance.
This creates a standalone file that can be used on other machines.
However, those other machines need to have access to the internet:
p = PlotlyJS.Plot(sin.(1:0.1:10))
open("f.html","w") do f
PlotlyJS.PlotlyBase.to_html(f, p; include_plotlyjs="cdn", full_html=true)
end
I just checked that this is as far as you can do as of today (version v0.8.18) as there is a bug in the source code of PlotlyBase.

Way to get detailed listing of all Pages properties in OneNote?

I have the latest OneNote on Windows 10. I'm trying to create a list of all my Pages in all the Notebooks. One line per Page, showing it's Name, Section and Notebook plus created date. As it's for import into (say) excel, be nice to have it delimited, say with # chars.
Nice Wines#Entertainment#Home Notebook#2021-10-01T06:57:32+10:00
I really only know Python and PowerShell. Is there any sample code you can suggest or another way to get this? Thanks.
I installed this PowerShell module and then another Stack Overflow user helped me get over another hurdle when using it.

caffe could not open or find file

I'm new to caffe and after successfully running an example I'm trying to use my own data. However, when trying to either write my data into the lmdb data format or directly trying to use the solver, in both cases I get the error:
E0201 14:26:00.450629 13235 io.cpp:80] Could not open or find file ~/Documents/ChessgameCNN/input/train/731_1.bmp 731
The path is right, but it's weird that the label 731 is part of this error message. That implies that it's reading it as part of the path instead of as a label. The text file looks like this:
~/Documents/ChessgameCNN/input/train/731_1.bmp 731
Is it because the labels are too high? Or maybe because the labels don't start with 0? I've searched for this error and all I found were examples with relatively few labels, about ~1-5, but I have about 4096 classes of which I don't always actually have examples in the training data. Maybe this is a problem, too (certainly for learning, at least, but I didn't expect for it to give me an actual error message). Usually, the label does not seem to be part of this error message.
For the creation of the lmdb file, I use the create_imagenet.sh from the caffe examples. For solving, I use:
~/caffe/build/tools/caffe train --solver ~/Documents/ChessgameCNN/caffe_models/caffe_model_1/solver_1.prototxt 2>&1 | tee ~/Documents/ChessgameCNN/caffe_models/caffe_model_1/model_1_train.log
I tried different image data types, too: PNG, JPEG and BMP. So this isn't the culprit, either.
If it is really because of my choice of labels, what would be a viable workaround for this problem?
Thanks a lot for your help!
I had the same issue. Check that lines in your text file don't have spaces in the end.
I was facing a similar problem with convert_imageset. I have solved just removing the trailing spaces in the text file which contains the labels.

Warning: last line of file ends without newline..... However it does?

I'm working on a tricky warning and, I just can't seem to get to the bottom of it. Here's what's going on:
I created a header file to define the register addresses for one of my sensor devices. My program works great however, upon compiling the project, I get the warning "device\device_reg.h(44): warning: #1-D: last line of file ends without a newline"
However, when I go to the file, it does appear to end in a new line. I remember that some text editors sometimes don't appropriately handle enter the newline. So, I deleted the newline, hit the return at the end of the new line, and recompiled. The warning persisted. I repeated this process with notepad++ and the original notepad in windows. Same results...
I am currently compiling c++ code in Keil 5.1.0.0 with an Arm compiler version 5.03.0.76
Any help would be greatly appreciated.
Thank you,
Beau
I had a similar problem with an included file. It turned out that the last line was indented. So when I hit the enter key the next line was indented leaving spaces on the new line. I hit back space to return the last row to the 0 position and the warning went away.
So, it wasn't the solution that I wanted. However, I resolved the issue. I combined the register map definitions with the class header file. I still don't know why I was getting this problem earlier and if anyone has any insights that would be great. However, as for now, this problem is solved.
Thank you.

Not seeing the entire output after the script runs

I'm not sure how to word this but I'm not getting the complete history after I run a script. I have some print statements and I see the results print out as it's running. But then when I go back and scroll vertically to take a closer look at the output, the results are gone. In other words the first lines are not displayed.
I have the following statement in my code so it should display all the lines
pd.set_option('display.max_rows', 180000)
What do I need to do to see all the output; not just the last part ?
You probably have to increase the size of the scrollback buffer. If you're using the QT console, there's a StackOverflow answer here that shows how to do that. If you're using ipython from another console, you'll have to look up how to change the size of the scrollback buffer there.