Search Results

Search: Posts Made By: Zam_1234
2,208
Posted By Zam_1234
Find common values in python list in ordered format
Hello All,
There are various codes available to find the intersection between two sets in python. But my case is the following:

I want to find the continual common pattern in different lists...
2,132
Posted By Zam_1234
I got you now RudiC. My mistake. I thought...
I got you now RudiC.
My mistake. I thought when you said dropping the quotes, you were referring to drop the quotes on the List Definition (line 1 in the original code), and thats where I got...
2,132
Posted By Zam_1234
Here is the code which worked: 1 # -- an...
Here is the code which worked:
1 # -- an example--
2 export GEM5_DIR=/usr/local/gem5
3 export BENCHMARK=./src/benchmark
4 #export ARGUMENT=./data/input.program
5
...
2,132
Posted By Zam_1234
But why would it convert into a single element? ...
But why would it convert into a single element?

I previously had another code, which was pretty similar (doing completely different tasks), it had same list likes and was able to loop through the...
2,132
Posted By Zam_1234
1: Yes line numbers are not included in the...
1: Yes line numbers are not included in the actual code.
2: I am not getting any obvious errors. after the "make all" command ends, I do get the print out of
Simulation done for a b c d
Bye

...
2,132
Posted By Zam_1234
Basic Shell script - Not working
Hello,
This is basic (i think). I am trying to run a shell script which would go into each folder (folder names defined in the list) and after entering would run some commands, once done, come out...
2,127
Posted By Zam_1234
I am assuming simple C[-1] would start from the...
I am assuming simple C[-1] would start from the end of line.
2,127
Posted By Zam_1234
Is there any way to count from the LSB (Which is...
Is there any way to count from the LSB (Which is start from the right hand side of the binaries in this case)?
2,127
Posted By Zam_1234
Text File with Binary Values processing
Hello all,
I have a txt file containing millions of lines. Below is the example:

{tx:be} head -50 file.txt
Instr1:...
2,018
Posted By Zam_1234
Make sense. I am editing the original post with...
Make sense. I am editing the original post with Comma Separated Values.

Thanks for your help. :-)
2,018
Posted By Zam_1234
Don, The files are CSVs. I manually typed them...
Don,
The files are CSVs. I manually typed them in here, adn this is not the actual file or data, But just the structure of the file.

You are correct, I do want the preserve the order "a.csv" in...
2,018
Posted By Zam_1234
Join 2 CSVs based on 1 key
Hello,
I have 2 csv as follows:

a.csv:
name,phone,adress,car[drive]
xy,1234,asbd
yz,2134,asbdf
tc,6789,salkdur

b.csv:
telphone,vehicle
2134,toyota
6789,bmw
1234,honda
What is...
1,941
Posted By Zam_1234
I got the script working. Below is the line of...
I got the script working. Below is the line of code:

awk ' $1==".dcache_rdata_wb" {split ($2, F,"["); split (F[2], Y, ":"); Z=$1; for(i=Y[1]; i>=0; i--) {$1 = Z i; $2 = F[1] "["i"]),"; print $1...
1,941
Posted By Zam_1234
I have attached the "lsu.v" file. I am trying to...
I have attached the "lsu.v" file. I am trying to change stuff inside the block "bw_r_dcd" (line: 1919):

Here I need to change ".dcache_rdata_wb" to ".dcache_rdata_wb63",...
1,941
Posted By Zam_1234
Search and Replace+append a text in python
Hello all,
I have a verilog file as following (part of it):
old.v:

bw_r_rf16x32 AUTO_TEMPLATE (
1957 // .rst_tri_en (mem_write_disable),
1958 .rclk ...
1,570
Posted By Zam_1234
Python update variable name in for loop
Hello all,
Not sure if this question has been answered already.

I have some xml Element variable as below:
child19 = core_elem_dcache.find('stat[@name="read_accesses"]')
child20 =...
2,830
Posted By Zam_1234
@Corona688: the average you see is:...
@Corona688:
the average you see is: avg(a[8],b[8],c[8])
2,830
Posted By Zam_1234
Import 2 columns from 8 .csv files into pandas df (side by side) and write a new csv
I have 8 .csv files with 16 columns and "n" rows with no Header. I want to parse each of these .csv and get column [0, 8] [#where column 0 is the value of x, y, z etc and column 8 is always the value...
4,302
Posted By Zam_1234
Thanks @Chubler_XL I was trying to do this...
Thanks @Chubler_XL

I was trying to do this in python. Started with a sample replacement of just 2 variables instead of all of them. It worked, but, I was hoping to print out each xml for all the...
4,302
Posted By Zam_1234
Expected new xml: ?xml version="1.0" ?>...
Expected new xml:

?xml version="1.0" ?> <component id="root" name="root">
<component id="system" name="system">
<param name="number_of_A" value="$colum1"/>
<param...
4,302
Posted By Zam_1234
Pass some data from csv to xml file using shell/python
Hello gurus,
I have a csv file with bunch of datas in each column. (see attached)

Now I have an .xml file in the structure of below:

?xml version="1.0" ?>
<component id="root" name="root">
...
4,822
Posted By Zam_1234
I understand your confusion. Here is hopefully...
I understand your confusion. Here is hopefully more clarified input file format that I have:

awk 'NR==1{print $0}' input.csv ...
4,822
Posted By Zam_1234
This worked. But why didn't the one I had worked?...
This worked. But why didn't the one I had worked? Seems like only change is I was using "NF" and you use the hardcoded number "16".

Also, if the number of columns change in the future, what is way...
4,822
Posted By Zam_1234
Add 8 columns at the end of .csv file using awk
Hello all,
I have a .csv file of 16 columns consists of bunch of numbers.
6.45E+01 1.17E+01 8.10E+04 8.21E+01 8.50E+00 1.20E+01 1.02E+01 1.88E+01 1.86E+04 3.53E+03 ...
2,692
Posted By Zam_1234
Save value from output of Corestat and save in a list for each core
I am trying to modify the "corestat v1.1" code which is in Perl.The typical output of this code is below:

Core Utilization
CoreId %Usr %Sys %Total
------ ...
Showing results 1 to 25 of 39

 
All times are GMT -4. The time now is 10:57 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy