# General Usage

**URL:** https://discourse.julialang.org/c/usage/6.md?page=928

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

**Page:** 929

---

## [Julia stops unexpectedly (after 10 mins of use)](https://discourse.julialang.org/t/julia-stops-unexpectedly-after-10-mins-of-use/16329)

<div class="topic-metadata">

**Author:** [@juliauser](https://discourse.julialang.org/u/juliauser)\
**Replies:** 7\
**Last updated:** [October 15, 2018, 2:11pm UTC](https://discourse.julialang.org/t/julia-stops-unexpectedly-after-10-mins-of-use/16329 "2018-10-15T14:11:47Z")

</div>

Hi, I am using Julia 0.7 on Atom. After few minutes of use, it suddenly stops with this message. called Tcl\_FindHashEntry on deleted table signal (6): Abort trap: 6 in expression starting at no file:0 \_\_pthread\_kill…

---

## [s=ArgParseSettings()](https://discourse.julialang.org/t/s-argparsesettings/16343)

<div class="topic-metadata">

**Author:** [@lannisite110](https://discourse.julialang.org/u/lannisite110)\
**Replies:** 1\
**Last updated:** [October 15, 2018, 1:37pm UTC](https://discourse.julialang.org/t/s-argparsesettings/16343 "2018-10-15T13:37:07Z")

</div>

julia VGGforw\_up.jl Testing vgg’s code on RGB-D dataset Dict{String,Any}(“epochs”=\>5,“lr”=\>1.0e-5,“nbatch”=\>100,“seed”=\>42,“gcheck”=\>0) ERROR: LoadError: UndefVarError: symbol not defined Stacktrace: \[1\] macro expan…

---

## [Passing parameters to \`test\`](https://discourse.julialang.org/t/passing-parameters-to-test/16314)

<div class="topic-metadata">

**Author:** [@gdkrmr](https://discourse.julialang.org/u/gdkrmr)\
**Replies:** 3\
**Last updated:** [October 15, 2018, 9:24am UTC](https://discourse.julialang.org/t/passing-parameters-to-test/16314 "2018-10-15T09:24:48Z")

</div>

Is it possible to pass a parameter to tests? Something like: (v1.0) pkg\> test MyPackage TYPE=LONG\_TEST

---

## [Sharing environments when using dev packages](https://discourse.julialang.org/t/sharing-environments-when-using-dev-packages/16334)

<div class="topic-metadata">

**Author:** [@j605](https://discourse.julialang.org/u/j605)\
**Replies:** 1\
**Last updated:** [October 15, 2018, 6:26am UTC](https://discourse.julialang.org/t/sharing-environments-when-using-dev-packages/16334 "2018-10-15T06:26:10Z")

</div>

I am using an environment that needs MAT.jl so I had to install it as a dev package with some fixes to make it work with 1.0. I want to share that environment with my laptop. But there is an issue where Pkg3 seems to har…

---

## [Modia requires ModiaMath 0.2.4 but uses 0.2.5-dev (surprising behaviour)](https://discourse.julialang.org/t/modia-requires-modiamath-0-2-4-but-uses-0-2-5-dev-surprising-behaviour/16312)

<div class="topic-metadata">

**Author:** [@MartinOtter](https://discourse.julialang.org/u/MartinOtter)\
**Replies:** 11\
**Last updated:** [October 15, 2018, 5:07am UTC](https://discourse.julialang.org/t/modia-requires-modiamath-0-2-4-but-uses-0-2-5-dev-surprising-behaviour/16312 "2018-10-15T05:07:49Z")

</div>

I thought that the new package manager has the big advantage that if package A requires package B in the version defined in the Project.toml file, then whenever A is used, it uses package B with this version, under all c…

---

## [eigen(tranpose(mat))](https://discourse.julialang.org/t/eigen-tranpose-mat/16317)

<div class="topic-metadata">

**Author:** [@unhandyandy](https://discourse.julialang.org/u/unhandyandy)\
**Replies:** 4\
**Last updated:** [October 14, 2018, 9:57pm UTC](https://discourse.julialang.org/t/eigen-tranpose-mat/16317 "2018-10-14T21:57:08Z")

</div>

Shouldn’t this work? julia\> pmat = \[ 0.3 0.5 0.2; 0.5 0.3 0.2; 0.5 0.4 0.1\] 3×3 Array{Float64,2}: 0.3 0.5 0.2 0.5 0.3 0.2 0.5 0.4 0.1 julia\> eigen(transpose(pmat)) ERROR: MethodError: no method matching eigen(…

---

## [Understanding performance using \`@btime\` and \`@code\_warntype\`, \`@code\_llvm\`, etc](https://discourse.julialang.org/t/understanding-performance-using-btime-and-code-warntype-code-llvm-etc/16293)

<div class="topic-metadata">

**Author:** [@dave.f.kleinschmidt](https://discourse.julialang.org/u/dave.f.kleinschmidt)\
**Replies:** 13\
**Last updated:** [October 14, 2018, 8:28pm UTC](https://discourse.julialang.org/t/understanding-performance-using-btime-and-code-warntype-code-llvm-etc/16293 "2018-10-14T20:28:36Z")

</div>

I’m struggling to get my head around some benchmarking and @code\_llvm inspecting that I’ve been doing. The background is I was curious what kind of overhead you get from creating an intermediate Normal distribution in a…

---

## [DataFrames cannot describe columns with #N/A DataValue](https://discourse.julialang.org/t/dataframes-cannot-describe-columns-with-n-a-datavalue/15278)

<div class="topic-metadata">

**Author:** [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Replies:** 3\
**Last updated:** [October 14, 2018, 6:19pm UTC](https://discourse.julialang.org/t/dataframes-cannot-describe-columns-with-n-a-datavalue/15278 "2018-10-14T18:19:59Z")

</div>

Where should I file this bug…? julia\> using DataFrames, DataValues julia\> x = DataFrame(a = \[DataValue{Any}()\]) 1×1 DataFrame │ Row │ a │ ├─────┼─────┤ │ 1 │ #NA │ julia\> describe(x) Unreachable reached at 0x129c9…

---

## [Please explain fine point of splatting syntax in macros](https://discourse.julialang.org/t/please-explain-fine-point-of-splatting-syntax-in-macros/16303)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 3\
**Last updated:** [October 14, 2018, 6:08pm UTC](https://discourse.julialang.org/t/please-explain-fine-point-of-splatting-syntax-in-macros/16303 "2018-10-14T18:08:21Z")

</div>

This line in base/namedtuples.jl looks like :( NamedTuple{$names,$types}(($(vals...),)) ) and I am asking about the ($(vals...),) part. The , and the outer ()s seemed redundant to me, but if I omit them, the expansio…

---

## [Extracting code excerpts automatically](https://discourse.julialang.org/t/extracting-code-excerpts-automatically/16313)

<div class="topic-metadata">

**Author:** [@janrpeters](https://discourse.julialang.org/u/janrpeters)\
**Replies:** 2\
**Last updated:** [October 14, 2018, 5:12pm UTC](https://discourse.julialang.org/t/extracting-code-excerpts-automatically/16313 "2018-10-14T17:12:08Z")

</div>

I have a self-referential problem: I code programs for a book and like to keep nice and long jupyter notebooks for teaching and developing. From these I would like to automatically extract all files needed as listings fo…

---

## [ERROR: LoadError: LoadError: UndefVarError: ASCIIString not defined](https://discourse.julialang.org/t/error-loaderror-loaderror-undefvarerror-asciistring-not-defined/16311)

<div class="topic-metadata">

**Author:** [@Ippokratis\_Karakotso](https://discourse.julialang.org/u/Ippokratis_Karakotso)\
**Replies:** 0\
**Last updated:** [October 14, 2018, 4:19pm UTC](https://discourse.julialang.org/t/error-loaderror-loaderror-undefvarerror-asciistring-not-defined/16311 "2018-10-14T16:19:35Z")

</div>

I am running the following code in Julia 0.6.4 with Jupyter notebook using RegERMs # define some toy data (XOR - example) np = 100 nn = 100 X = \[randn(int(np/2),1)+1 randn(int(np/2),1)+1; randn(int(np/2-0.5),1)-1 randn…

---

## ["Unsatisfiable requirements detected" error with unregistered packages](https://discourse.julialang.org/t/unsatisfiable-requirements-detected-error-with-unregistered-packages/16307)

<div class="topic-metadata">

**Author:** [@crbinz](https://discourse.julialang.org/u/crbinz)\
**Replies:** 8\
**Last updated:** [October 14, 2018, 4:13pm UTC](https://discourse.julialang.org/t/unsatisfiable-requirements-detected-error-with-unregistered-packages/16307 "2018-10-14T16:13:16Z")

</div>

Can someone help me understand what this means? (v0.7) pkg\> add "git@\<snippedurl\>:cbinz/Arc.jl" Updating git-repo \`git@\<snippedurl\>:cbinz/Arc.jl\` Resolving package versions... ERROR: Unsatisfiable requirements detect…

---

## [From String vec only rows starting like "bib" . What wrong?](https://discourse.julialang.org/t/from-string-vec-only-rows-starting-like-bib-what-wrong/16308)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 2\
**Last updated:** [October 14, 2018, 3:52pm UTC](https://discourse.julialang.org/t/from-string-vec-only-rows-starting-like-bib-what-wrong/16308 "2018-10-14T15:52:26Z")

</div>

I need only rows of bazab wnen strings are starting from “bib” . What wrong ? julia\> (x-\>x(1:3)==“bib”,bazab) (#117, SubString{String}\[“babilońskość”, “bab tterka”, “bacewiczówna”, “bachanalijka”, “bac kawicowo”, “b…

---

## [Is boolean indexing 100 times slower in 1.0?](https://discourse.julialang.org/t/is-boolean-indexing-100-times-slower-in-1-0/16286)

<div class="topic-metadata">

**Author:** [@misha\_mikhasenko](https://discourse.julialang.org/u/misha_mikhasenko)\
**Replies:** 10\
**Last updated:** [October 14, 2018, 11:42am UTC](https://discourse.julialang.org/t/is-boolean-indexing-100-times-slower-in-1-0/16286 "2018-10-14T11:42:38Z")

</div>

d = rand(100) mask = \[fill(false,20)...,fill(true,80)...\]; @time for i in 1:100000 d\[mask\] end Julia-1.0 and 0.7 3.038767 seconds (41.20 M allocations: 1.197 GiB, 4.90% gc time) Julia-0.6.4 0.029932 seconds…

---

## [Type inference when generating a NamedTuple](https://discourse.julialang.org/t/type-inference-when-generating-a-namedtuple/16222)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 3\
**Last updated:** [October 14, 2018, 9:03am UTC](https://discourse.julialang.org/t/type-inference-when-generating-a-namedtuple/16222 "2018-10-14T09:03:42Z")

</div>

This is an MWE simplified from a real-world problem — I have a T \<: NamedTuple type, and would like to generate an value ::T from functions that generate fields based on type, to be named appropriately. using Random st…

---

## [Is coninctio/alternativ... of all BitArray?](https://discourse.julialang.org/t/is-coninctio-alternativ-of-all-bitarray/16287)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 8\
**Last updated:** [October 14, 2018, 6:35am UTC](https://discourse.julialang.org/t/is-coninctio-alternativ-of-all-bitarray/16287 "2018-10-14T06:35:35Z")

</div>

julia\> .&(a) 6-element BitArray{1}: true false false false false false julia\> &(a) ERROR: syntax: misplaced “&” expression i need somthing like (true & false & false & false & false ) on "a " BitArray

---

## [A startup.jl for packages](https://discourse.julialang.org/t/a-startup-jl-for-packages/16297)

<div class="topic-metadata">

**Author:** [@sswatson](https://discourse.julialang.org/u/sswatson)\
**Replies:** 4\
**Last updated:** [October 14, 2018, 6:25am UTC](https://discourse.julialang.org/t/a-startup-jl-for-packages/16297 "2018-10-14T06:25:30Z")

</div>

Suppose that you want to run some custom initialization code whenever a particular package is loaded. For example, perhaps you want to configure some display options for a plotting package. The best solution I can think…

---

## [BigInt precision issue](https://discourse.julialang.org/t/bigint-precision-issue/16292)

<div class="topic-metadata">

**Author:** [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Replies:** 3\
**Last updated:** [October 14, 2018, 3:38am UTC](https://discourse.julialang.org/t/bigint-precision-issue/16292 "2018-10-14T03:38:53Z")

</div>

I am finding the cube root of a big number. When I raise the answer to the power of 3, I ended up with a different number. julia\> y = 22053164139311340310464407676205419848010912163512227891805357868514519174628044491…

---

## [\`where T\` vs \`where {T}\`](https://discourse.julialang.org/t/where-t-vs-where-t/16296)

<div class="topic-metadata">

**Author:** [@pochoi](https://discourse.julialang.org/u/pochoi)\
**Replies:** 2\
**Last updated:** [October 14, 2018, 3:14am UTC](https://discourse.julialang.org/t/where-t-vs-where-t/16296 "2018-10-14T03:14:10Z")

</div>

When I read Julia source codes, sometimes the type parameterization writes where T, sometimes where {T}. Are they different or the same?

---

## [CSV.jl error - cannot convert an object of type WeakRefString](https://discourse.julialang.org/t/csv-jl-error-cannot-convert-an-object-of-type-weakrefstring/14603)

<div class="topic-metadata">

**Author:** [@tk3369](https://discourse.julialang.org/u/tk3369)\
**Replies:** 13\
**Last updated:** [October 13, 2018, 10:14pm UTC](https://discourse.julialang.org/t/csv-jl-error-cannot-convert-an-object-of-type-weakrefstring/14603 "2018-10-13T22:14:57Z")

</div>

Any idea what how i can work around this error? This is Julia 0.6. julia\> df = CSV.read(file); MethodError: Cannot \`convert\` an object of type WeakRefString{UInt8} to an object of type Missings.Missing This may have a…

---

## [Custom Iterators and Last Value](https://discourse.julialang.org/t/custom-iterators-and-last-value/16291)

<div class="topic-metadata">

**Author:** [@gideonsimpson](https://discourse.julialang.org/u/gideonsimpson)\
**Replies:** 2\
**Last updated:** [October 13, 2018, 8:10pm UTC](https://discourse.julialang.org/t/custom-iterators-and-last-value/16291 "2018-10-13T20:10:33Z")

</div>

I’m trying to write an iterator for a custom data structure with the following as a test code: struct DataStruct{TF\<:AbstractFloat, TI\<:Integer} X::Vector{TF} Y::Vector{TI} end function Base.length(D::DataStruct)…

---

## [How to select multiple items using DataFramesMeta?](https://discourse.julialang.org/t/how-to-select-multiple-items-using-dataframesmeta/16231)

<div class="topic-metadata">

**Author:** [@youngjae.woo](https://discourse.julialang.org/u/youngjae.woo)\
**Replies:** 7\
**Last updated:** [October 13, 2018, 8:06pm UTC](https://discourse.julialang.org/t/how-to-select-multiple-items-using-dataframesmeta/16231 "2018-10-13T20:06:30Z")

</div>

using DataFrames, DataFramesMeta x = \["a", "b", "c", "a", "c", "d"\] df = DataFrame(x=x, y = 1:length(x)) z = \["a", "c"\] How do I query the items in z in df using DataFramesMeta? @where(df, in(z, :x)) didn’t work. It’s…

---

## [A\[2,:\] = 5;](https://discourse.julialang.org/t/a-2-5/16278)

<div class="topic-metadata">

**Author:** [@janrpeters](https://discourse.julialang.org/u/janrpeters)\
**Replies:** 3\
**Last updated:** [October 13, 2018, 5:55pm UTC](https://discourse.julialang.org/t/a-2-5/16278 "2018-10-13T17:55:34Z")

</div>

I have code with a lot of statements like A = zeros(Float64,10,10); A\[2,:\] = 5; which worked fine in Julia 0.6.2. It gets this error message: MethodError: no method matching setindex\_shape\_check(::Int64, ::Int64, ::I…

---

## [Unsatisfiable requirements detected for package JLD\[4138dd39\]](https://discourse.julialang.org/t/unsatisfiable-requirements-detected-for-package-jld-4138dd39/16271)

<div class="topic-metadata">

**Author:** [@lannisite110](https://discourse.julialang.org/u/lannisite110)\
**Replies:** 1\
**Last updated:** [October 13, 2018, 9:11am UTC](https://discourse.julialang.org/t/unsatisfiable-requirements-detected-for-package-jld-4138dd39/16271 "2018-10-13T09:11:11Z")

</div>

add JLD Resolving package versions… ERROR: Unsatisfiable requirements detected for package JLD \[4138dd39\]: JLD \[4138dd39\] log: ├─possible versions are: \[0.5.0-0.5.9, 0.6.0-0.6.11, 0.8.0-0.8.3\] or uninstalled ├─restr…

---

## [Array with user-defined number of dimensions](https://discourse.julialang.org/t/array-with-user-defined-number-of-dimensions/16268)

<div class="topic-metadata">

**Author:** [@Ferran\_Mazzanti](https://discourse.julialang.org/u/Ferran_Mazzanti)\
**Replies:** 1\
**Last updated:** [October 13, 2018, 7:55am UTC](https://discourse.julialang.org/t/array-with-user-defined-number-of-dimensions/16268 "2018-10-13T07:55:29Z")

</div>

Hi folks, just a quick (and probably stupid) question. I need to define an array whose unmber of dimensions is given by the user. The user should provide an inpt integer n and, depending on its value the array must chan…

---

## [How to find which Python Conda.jl is using?](https://discourse.julialang.org/t/how-to-find-which-python-conda-jl-is-using/16258)

<div class="topic-metadata">

**Author:** [@amrods](https://discourse.julialang.org/u/amrods)\
**Replies:** 1\
**Last updated:** [October 12, 2018, 10:35pm UTC](https://discourse.julialang.org/t/how-to-find-which-python-conda-jl-is-using/16258 "2018-10-12T22:35:25Z")

</div>

How do I find which Python, and the location, Conda.jl is currently using?

---

## [Why does \`@edit\` fail with keyword argument?](https://discourse.julialang.org/t/why-does-edit-fail-with-keyword-argument/16235)

<div class="topic-metadata">

**Author:** [@chobbes](https://discourse.julialang.org/u/chobbes)\
**Replies:** 7\
**Last updated:** [October 12, 2018, 10:01pm UTC](https://discourse.julialang.org/t/why-does-edit-fail-with-keyword-argument/16235 "2018-10-12T22:01:36Z")

</div>

With Julia-v1.0: julia\> @edit isapprox(10, 11; atol = 2) ERROR: could not determine location of method definition Stacktrace: \[1\] functionloc at .\\reflection.jl:957 \[inlined\] \[2\] functionloc at .\\reflection.jl:967 \[in…

---

## [I released a package, and now it stopped building](https://discourse.julialang.org/t/i-released-a-package-and-now-it-stopped-building/16184)

<div class="topic-metadata">

**Author:** [@schnetter](https://discourse.julialang.org/u/schnetter)\
**Replies:** 8\
**Last updated:** [October 12, 2018, 9:41pm UTC](https://discourse.julialang.org/t/i-released-a-package-and-now-it-stopped-building/16184 "2018-10-12T21:41:13Z")

</div>

I just released the package ASDF.jl. I was using it in another project by pointing to its Github repository, and this worked fine. Now that it has been released (without any other changes), it doesn’t build any more. Th…

---

## [Gitlab CI Caching](https://discourse.julialang.org/t/gitlab-ci-caching/16255)

<div class="topic-metadata">

**Author:** [@adamslc](https://discourse.julialang.org/u/adamslc)\
**Replies:** 0\
**Last updated:** [October 12, 2018, 8:47pm UTC](https://discourse.julialang.org/t/gitlab-ci-caching/16255 "2018-10-12T20:47:45Z")

</div>

I’m trying to use Gitlab-ci’s caching features to avoid downloading and building testing dependencies multiple times (one for tests and once to build docs). Everything seems to be working fine, but Julia can’t seem to fi…

---

## [N-dimensional implementations](https://discourse.julialang.org/t/n-dimensional-implementations/16191)

<div class="topic-metadata">

**Author:** [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Replies:** 19\
**Last updated:** [October 12, 2018, 8:27pm UTC](https://discourse.julialang.org/t/n-dimensional-implementations/16191 "2018-10-12T20:27:04Z")

</div>

I am trying to generalize an algorithm for N-dimensional arrays, but there are many code patterns for which I don’t have a solution yet. I will use this thread to ask a few questions. How do you generalize the following…

[Previous page](https://discourse.julialang.org/c/usage/6.md?page=927)

[Next page](https://discourse.julialang.org/c/usage/6.md?page=929)
