I'm starting to learn how convolutional neural networks work, and I have a question regarding the filters. Apparently, these are randomly generated when the model is generated, and then as the data is fed, these are corrected accordingly as with the weights in backtracking. However, how does this work in filters? To my understanding, backtracking works by calculating how much an actual weight contributed to the total error after an output has been predicted, and then correct it accordingly. I've …
I would like to disallow the authors (of posts for example) in the file robots.txt. In fact, I noticed that for some of my sites, Google indexed the authors of articles, which I don't want to. Someone thinks is it possible ? (I tried something like Disallow: /author/ but I'm not sure it works...) Thank you in advance, ArbreMojo.
Is there a similar replacement of the hook posts_where for comments (WP_Comment_Query)? I need to modify the where clause for a comments query like it is shown in this tutorial (“4. Sub custom field values”) for posts. The only hook I found is comments_pre_query, but the property $query->meta_query_clauses[ 'where' ] is protected.
df <- tibble(x1=factor(c("S1", "S1", "S2", "S2")), y=factor(c(1, 1, 0, 1))) md <- rpart(formula=y~., data=df, method="class", control=rpart.control(minsplit=2, cp=0)) nrow(md$frame) #outputs 1 Consider the split left child node: "S1", 1 "S1", 1 Right child node: "S2", 0 "S2", 1 Here the gain in gini would be ${1 \over 8} = 0.125$ Why is rpart not doing this split?
Is it possible to create links to a network folder from within a table? A colleague and myself have been struggling to link certain table cells to a network folder, for example: DB - Database would be linked to a network folder of the same name. What we have tried: Using <a href="http://\\networkdrive\folder1\folder2\folder3\DB - Databases">DB - Databases</a> returns a 'Sorry, the page was not found' error from our storage device Using <a href="file:///path/to/file.html">file</a> did not open the desired folder location …
I'm trying to build an encoder-decoder network in Keras to generate a sentence of a particular style. As my problem is unsupervised i.e. I don't have the ground truths for the generated sentences, I use a classifier to help during training. I pass the decoder's output into the classifier to tell me what style the decoded sentence is. The decoder outputs a softmax distribution which I was intending to feed straight into the classifier but I realised that it has …
I'm trying to early exit a function within the "init" hook if it's not a front-end page. This is what I have so far, but it's definitely running on wp-json endpoints. Does anyone have a complete "early exit" clause that will ensure this is ONLY running on front-end pages? add_action('init', 'test'); function test() { if ( is_admin || wp_doing_ajax() ) { return; } // Do stuff here }
I recently upgraded to WordPress 5.9, and I'm now getting the following error in a custom block: Cannot update a component (`Unknown`) while rendering a different component (`Edit`). The code is as below: export default function Edit( props ) { const {attributes, setAttributes} = props const {customClass, summaryCount} = attributes const childBlockCount = useSelect(select => select('core/block-editor')).getBlockCount(props.clientId)) const ALLOWED_BLOCKS = [ ... ] function Placeholder() { return <div className="event-summary-placeholder"></div> } useEffect(() => { if (childBlockCount !== summaryCount) setAttributes({summaryCount: childBlockCount}) }, [childBlockCount]) …
I'm working with a set of large Wordpress installs with 50-150k posts, each with 40-50 custom fields. The installs are very basic, with limited plugins (less than 5), and a default Wordpress theme (i.e. twenty twelve, etc.). The sites are on 1-Core, 2GB RAM, SSD VPS servers. These are all private installs, with no public front-end or web traffic. Automatic updater, auto-update core, and revisions are all disabled. I have no featured images or other media on the edit post …
I am trying to add pagination for my Archive. I want to show 12 posts per page and then show the 'next' / 'previous' buttons. When I manually change the value of the $paged variable, the 1 into a 2 it works. When I click the Next button on the archive page, it loads a very weird theme page. The url looks like: '/page/2/'. What am I doing wrong? This is the code I wrote so far: <?php global $paged,$wp_query; …
when using matlab command 'fitctree' for classification purpose, and I change the order of the attributes I do not find the same Tree and thus the same classificaiton error? why? CART algorithm does take account on the attributes firstly introduced ?
I want to implement an FPGA code or hardware code of a Keras model. As a first step, I want to find the number of mathematical operations required to evaluate a predicted output given a model. The model below is a two-class classifier and a sample of input is a vector of size 232X1. The model is: model.add(keras.layers.Dense(5, input_dim=232, activation='relu')) model.add(keras.layers.Dense(1, activation='sigmoid')) The question is given in the model above, how many mathematical operations (plus, minus, multiplication, division) are required …
I have a setup similar to this: function get_type_data($val) { // Get the data from the DB where the ID is $val and return it. } add_action('my_hook', array($this, 'get_type_data'), 10, 1); I need to repeat this callback for several results of another callback, which I was thinking of doing like this: // Get the types first, then... foreach ($type as $val) { add_action('my_hook', array($this, 'get_type_data'), 10, 1); do_action('my_hook', $val); } But it only does the first one. I then did …
I'm trying to create a template file for a custom taxonomy archive page but I keep getting a 404 error when trying to access that archive page. Basically something like: domain.com/quizzes/quiz-levels/ I managed to create template files for /quizzes/ and /b1-intermediate/ (or whatever the level is), but when I land on "domain.com/quizzes/quiz-levels/" I get a 404 error doesn't take any template file. What I'm aiming for is the following: domain.com/quizzes/ : To show all the quizzes (Works) domain.com/quiz-post-slug/ : To …
How do I add class labels to the confusion matrix? The label display number in the label not the actual value of the label Eg. labels = ['A','B','C','D','E','F','G','H','I','J','K','L','M','N','O','P','Q','R','S','T','U','V','W','X','Y','Z'] Here is the code I used to generate it. x_train, y_train, x_test, y_test = train_images, train_labels, test_images, test_labels model = KNeighborsClassifier(n_neighbors=7, metric='euclidean') model.fit(x_train, y_train) # predict labels for test data predictions = model.predict(x_test) # Print overall accuracy print("KNN Accuracy = ", metrics.accuracy_score(y_test, predictions)) # Print confusion matrix cm = confusion_matrix(y_test, predictions) plt.subplots(figsize=(30, …
I have a HTML form with 2 select boxes with multiple selection. I get the selected values on form submit with jQuery and store them in 2 different arrays: $('#assign_categories_form').on('submit', function (event) { event.preventDefault(); var documents = []; $.each($("#documents_auth_select option:selected"), function(){ documents.push($(this).val()); }); if (documents.length === 0) { $('#modal_message_title').html( 'Nessun documento selezionato...' ); $('#modal_message_p').html( 'È necessario selezionare almeno un documento a cui assegnare delle categorie!' ); $('#modal_message_div').modal(); return false; } var categories = []; $.each($("#dl_categories option:selected"), function(){ categories.push($(this).val()); }); if …
I downloaded: !git clone https://www.github.com/matterport/Mask_RCNN.git os.chdir('Mask_RCNN') And I've got an error: which version I should have of Keras? WARNING:tensorflow:From /usr/local/lib/python3.5/dist-packages/keras/backend/tensorflow_backend.py:1154: calling reduce_max (from tensorflow.python.ops.math_ops) with keep_dims is deprecated and will be removed in a future version. Instructions for updating: keep_dims is deprecated, use keepdims instead WARNING:tensorflow:From /usr/local/lib/python3.5/dist-packages/keras/backend/tensorflow_backend.py:1188: calling reduce_sum (from tensorflow.python.ops.math_ops) with keep_dims is deprecated and will be removed in a future version. Instructions for updating: keep_dims is deprecated, use keepdims instead WARNING:tensorflow:From /usr/local/lib/python3.5/dist-packages/keras/backend/tensorflow_backend.py:1290: calling reduce_mean (from tensorflow.python.ops.math_ops) with keep_dims …
I have some dataset which contains different paramteres and data.head() looks like this Applied some preprocessing and performed Feature ranking - dataset = pd.read_csv("ML.csv",header = 0) #Get dataset breif print(dataset.shape) print(dataset.isnull().sum()) #print(dataset.head()) #Data Pre-processing data = dataset.drop('organization_id',1) data = data.drop('status',1) data = data.drop('city',1) #Find median for features having NaN median_zip, median_role_id, median_specialty_id, median_latitude, median_longitude = \ data['zip'].median(),\ data['role_id'].median(),\ data['specialty_id'].median(),\ data['latitude'].median(),\ data['longitude'].median() data['zip'].fillna(median_zip, inplace=True) data['role_id'].fillna(median_role_id, inplace=True) data['specialty_id'].fillna(median_specialty_id, inplace=True) data['latitude'].fillna(median_latitude, inplace=True) data['longitude'].fillna(median_longitude, inplace=True) #Fill YearOFExp with 0 data['years_of_experience'].fillna(0, inplace=True) target = dataset.location_id …
I am trying to load my site's child theme's css after Bootstrap CDN css in wordpress. I tried using these code but it doesn't work. The Bootstrap css is not overriden. What should I do to fix that? function override_css() { wp_enqueue_style( 'bootstrap.min', 'https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css' ); wp_enqueue_style( 'style', get_stylesheet_directory_uri() . '/style.css', array(), '1.0.0', true ); } add_action( 'wp_enqueue_scripts', 'override_css' );
How can I change this code $posts = get_posts(array('post_type'=> 'lesson', 'post_status'=> 'publish', 'suppress_filters' => false, 'posts_per_page'=>-1)); //here you add the HTML of the dropdown you add something like echo '<p>Select the lesson: <select name="_dappcf_i_dropdown" class="widefat" style="width:170px" >'; foreach ($posts as $post) { echo '<option value="', $post->ID, '"'; if ($my_dropdown == $post->ID){echo ' selected="selected"';} echo '>'.$post->post_title.'</option>'; } echo '</select>'; } to echo the title of the selected post in page template with the URL of of SELECTED post(the title should be …
I want to make a WordPress with multiple languages. I have two WordPress sites and I want them to use the same domain name. Site 1: http://example.com/en Site 2: http://example.com/de Is this possible? What information do I need to search for to find a tutorial. I don't want to use a plugin like WPML to translate content, I have to use multiple WordPress sites.
I'm trying to forecast Real estate Price , it's not a prédiction. But a forecast Like the Price of a an appartement in 2023 or 2024, i'm asking about how should be my dataset ? Can I use a dataset from 2018 to 2021 of 13 columns You can find the dataset here: https://www.kaggle.com/datasets/mrdaniilak/russia-real-estate-20182021 Date, area, kitchen_are, nb_rooms Please note that every row is a new house indépendant from others, I'm having this dataset by scrapping a website of ads …
So I have two datasets (dataset1, dataset2) that are related in this way: (Think of a checkout counter in a supermarket) A customer comes in with an item. The cashier registers the item to dataset1 directly, in particular registering the current time. The cashier does the usual cashier thing (scanning the item, waiting for the customer to pay, point is there is some time gap). After the customer paid, now the cashier needs to register the sale to dataset2, including …
Yesterday I posted this thread Regularizing the intercept where I had a question about penalizing the intercept. In short, I asked wether there exist cases where penalizing the intercept leads to a lower expected prediction error and the answer was: Of course there exist scenarios where it makes sense to penalize the intercept, if that aligns with domain knowledge. However in real world, more often we do not just penalize the magnitude of intercept, but enforce it to be zero. …
I am new to this field and I was reading a paper "Predicting citation counts based on deep neural network learning techniques". There the authors describe the code that they implemented if someone wants to reproduce the results. I tried to do this but I am not sure if I succeeded. Here is their description: -RNN module - SimpleRNN -Output dimension of the encoder - 512 -The output layer - Dense layer -Activation function - ReLU -Overfitting prevention technique - …
I have access to the admin panel, and everything works fine. I can click settings->reading and change anything I want to. But if I click settings->permalinks I get a 500 internal server error. Here's what I've tried: I deleted the .htaccess file - nothing changed. I edited the .htaccess (because I am migrating this site to a new domain) and now I have all the page links working on the front end AND all the admin links EXCEPT permalinks. In …
I have a retail store dataset, and I am interested to do some time series clustering on this data, what idea you find interesting for this purpose? I have so far: What sales trends there are across time? What products customers will purchase at what time? Customer segmentation across time? Any better ideas?
I am working on a regression problem and building a model using Random Forest Regressor but while trying to get the accuracy I am getting ValueError: continuous is not supported. train=pd.read_csv(r"C:\Users\DELL\OneDrive\Documents\BigMart data\Train.csv") test=pd.read_csv(r"C:\Users\DELL\OneDrive\Documents\BigMart data\Test.csv") df=pd.concat([train,test]) df.head() After Data Preprocessing and Visualization, I have tried to build the model : Please help with the error
When i run my code with 5 epochs, code gets stuck at first epoch and run continuesly. I tried applying various parameters but couldn't make it. here is my code... import tensorflow as tf import numpy as np import os from google.colab import drive from tensorflow.keras.preprocessing.image import ImageDataGenerator from tensorflow import keras from tensorflow.keras.layers import Dense, Conv2D, Flatten, Dropout, MaxPooling2D training_path = 'drive/My Drive/tesla' validation_path = 'drive/My Drive/validation' training_generator = ImageDataGenerator(rescale=1.0/255) validation_generator = ImageDataGenerator(rescale=1.0/255) training_set = training_generator.flow_from_directory(batch_size=2, directory=training_path, target_size=(150,150), class_mode='binary', …
Here's my setup: Parent "Gallery" page: _regular page, not custom type or anything _ Several "Project" child pages (could be as few as 1, unlimited number): also normal pages Child pages will either have meta boxes or custom fields for entering stuff into my pre-formatted areas. I don't care if it's meta boxes or custom fields, whatever is figure-outable! I'm using standard WP-provided code to show Child page titles and the_content on the Parent page. <?php $mypages = get_pages( array( …
There are some easy and comprehensive textbooks covering many deep learning concepts using PyTorch in detail. But, I am a little dissatisfied with the weightage given to RNNs compared to CNNs. I mean, some textbooks did not cover RNN at all. I am in need of learning NLP using PyTorch to great detail. So, I want the list of books or a single book that covers RNN, LSTM, etc., using PyTorch in great detail i.e., from beginner to advanced. I …
Seaborn barplot has three parameters. x, y, hue : names of variables in data or vector data, optional Question What is hue? It seems the attribute to plot but why it is called "hue" because when I googled, the result is about color? Google Hue - Wikipedia Hue is one of the main properties (called color appearance parameters) of a color, defined technically (in the CIECAM02 model)
I have a series of 15 frames with (60 rows x 50 columns). Over the course of those 15 frames, the moon moves from the top left to the bottom right. Data = https://github.com/aiqc/AIQC/tree/main/remote_datum/image/liberty_moon I am attempting a walk forward autoencoder where: The input data is a 60x50 image. The evaluation label is a 60x50 image from 2 frames later. All data is scaled between 0-1. model = keras.models.Sequential() model.add(layers.Conv1D(64*hp['multiplier'], 3, activation='relu', padding='same')) model.add(layers.MaxPool1D( 2, padding='same')) model.add(layers.Conv1D(32*hp['multiplier'], 3, activation='relu', padding='same')) …