Help with updating a legacy Julia code
@gfaccin wrote: Hi all, I’m completely new to Julia. I’ve got a Julia simulation code that seems to have been written in an old version of Julia. Thus, it uses a lot of deprecated syntax which fails...
View ArticleThis if statements is not work properly
@dialektike wrote: julia> function step_function(x) if x > 0 return 1 eles return 0 end end step_function (generic function with 1 method) julia> x = [-1.0, 1.0, 2.0] 3-element...
View ArticleIs there a Julia equivalent for python's .remove() function?
@aschimmichanga wrote: I have tried deleteat!(arr, findfirst(item,arr)) but it gives me an error. Is it deprecated? Posts: 17 Participants: 4 Read full topic
View ArticleInteger overflow in cumprod (cumulative product) output
@1634 wrote: The cumulative product vector of a series of linear positive numbers (show in plot(cump1) ) contains negative num and zeros(in plot(cump2)). I checked available documentations carefully...
View ArticleKey and value from Dictionary
@ar12y wrote: Hi, I have the following Dictionary called states: states=Dict{Any,Any}((0, 0) => Array{Any,1}[[[0], (0, 0), Any[0, 0]], [[1], (1, 0), Any[1, 1]]],(1, 0) => Array{Any,1}[[[0], (0,...
View ArticleHow to save multiple output lines to a txt or csv file?
@HelgavonLichtenstein wrote: Similar to How do I save the output to .txt file?, I would like to know how to save several output lines into a file. Currently my function runs a for loop, and if certain...
View Article"dispatch" on whether or not a matrix is symmetric? (aka should I use a...
@evanfields wrote: Short version: is a pattern like issymmetric(x) && (x = Symmetric(x)) type-unstable, and will it have performance consequences? Details below. I have a user-facing function...
View ArticleConvert "Time of the day" to Total Minute or Total Second
@Eric_Chen wrote: tt = Time(now()) --> give me a time, e.g. 2 hour, 10 minute, 5 second, What is the most efficient / elegant way to convert it to Total Minutes? i.e. 2 * 60 + 10 = 130 (either Int...
View ArticleFlux Regularisation in Julia at the layer level
@Ed_Austin wrote: Hi there I have seen the examples but I am still unclear as to how to apply per-layer regularisation, the examples seem to show a single layer network or applying regularisation to...
View ArticleCannot run Zygote in Julia
@jiaqi19s wrote: When I run using Zygote, it stuck at pre-compiling without any error msg. Here is what shows in REPL. (v1.3) pkg> add Zygote Resolving package versions… Installed...
View ArticleOAuth 2.0 Authentication in pure Julia
@ASF wrote: I want to grab some data through an API call but I need to authenticate my requests via oauth2. What is the easiest way to do this in pure Julia? Posts: 2 Participants: 2 Read full topic
View ArticleCollect syntax: to include the last value
@ArchieCall wrote: (topic withdrawn by author, will be automatically deleted in 24 hours unless flagged) Posts: 1 Participants: 1 Read full topic
View ArticleHello everybody, and a question on REPL
@Darione wrote: Hello everyone. I am a beginner in Julia, but have used Python several times in the past and am used to using REPL to develop. I was now trying out Julia’s REPL, in the Juno editor. I...
View ArticleHow to know why a Julia package is downgraded?
@homocomputeris wrote: Sometimes packages seem to be randomly downgraded while update is run: (v1.3) pkg> update Updating registry at `~/.julia/registries/General` Updating git-repo...
View ArticleInner contructor with parametric type
@aaraujo71 wrote: I am trying to create a structure where parameter types can either be given explicitly or are inferred automatically from the arguments. However, I also would like to define the...
View ArticleIn as few lines as possible describe why you love julia
@ckneale wrote: In as few lines of coherent code as possible show why you love Julia I’ll kick this off with a silly example: message = Dict( [1,2,3,4] .=> ["why", "is", "julia", "great?"]) result...
View ArticleHow to update vertex / node color in a loop using Metagraphs
@Imran_Mustafa wrote: New user here. I was wondering how we can update the vertex / node color in a loop and display the updated graph in the same loop as exampled below (the example is for...
View ArticleCustom StaticArray type
@tomtom wrote: from StaticArrays doc, we can “easily” create our own StaticArray type… unfortunately no example is provided on the doc… could someone be nice enough to post an example (of immutable...
View ArticleIssues installing IJulia
@Romero_Azzalini wrote: Hi, unfortunately I’m not the most experienced Linux user and when I try to Pkg.build(“IJulia”) I always get the following error msg INFO: Building Conda INFO: Building MbedTLS...
View ArticleSame function two different outputs
@olabaz wrote: (topic withdrawn by author, will be automatically deleted in 24 hours unless flagged) Posts: 1 Participants: 1 Read full topic
View Article